xwikisas / application-diagram

Create various types of diagrams using draw.io
GNU Lesser General Public License v2.1
0 stars 5 forks source link

Can't export a diagram as PDF #270

Open ane-gabriela opened 1 month ago

ane-gabriela commented 1 month ago

Preconditions: Have a diagram page created with added shapes.

  1. Edit the diagram page
  2. Click on File > Export as > PDF...
  3. Click on Export
  4. Choose a name for the diagram
  5. Click on Download

Expected results: The diagram is exported as PDF.

Actual results: The diagram isn't exported

PDFExport

Environment: Windows 11, Chrome 125. Cloud XWiki 15.10.8, Diagram Application (Pro) 1.20.4

mflorea commented 1 month ago

Note that here are two ways you can export a diagram to PDF:

So we need to check:

oanalavinia commented 3 weeks ago

I am still investigating on this issue, couldn't find the root cause yet.

It's important to mention that the structure of the request altered a little on newer drawio versions. For example there are more parameters for this method and these could be required for the request to work. So a drawio upgrade seems necessary anyway. On another note, I did tried locally to apply these changes and the export still doesn't work, but I might be missing something (there are a lot of changes to consider). Unfortunately, the request response is not giving that much information. I would suggest to go on with the drawio upgrade and that come back at this issue

Until this is fixed, it's important to know that File -> Print could be used as a workaround, and it's actually safer since you don't send your data to an external server. Check https://www.drawio.com/blog/export-pdf#secure-pdf-generation

ilieandriuta commented 1 week ago

Issue reproduced too on XWiki 16.4.0 using Diagram Application (Pro) 1.20.5.