line / conflr

Post R Markdown documents to Confluence

Home Page:https://line.github.io/conflr/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Issues publishing with KableExtra

Stephonomon opened this issue · comments

When I include a table from Kable, I get the following error

Checking the existing images...
Uploading the images...
Uploading the document...
Error in read_xml.raw(charToRaw(enc2utf8(x)), "UTF-8", ..., as_html = as_html,  : 
  error parsing attribute name [68]

Example code chunk

library(kableExtra)
test <- structure(list(Name = "Person's name", Specialty = "Acquired Auto Dysfunction", 
    `Builder Type` = "Provider Builder", Email = "email@yahoo.com"), row.names = 1L, class = "data.frame")
kbl(test)

I am having a similar issue publishing tables with datatable.

I think it is because Confluence has its own table object, and these packages do not write their tables in a form that the Confluence REST API can recognize to create that table object.

See this Atlassian post for using their API to create Confluence tables: https://community.atlassian.com/t5/Marketplace-Apps-Integrations/Create-a-table-in-Confluence-from-a-REST-API-call/ba-p/1393107

I also have a SO post on the issue you may want to watch or contribute to: https://stackoverflow.com/q/73395370/9806500