Io.failed on export to pdf with empty folder

I’m trying to export pretty simple element to pdf but I’m getting error io.failed. The error occurs if there is empty folder next to the item I’m exporting. pdf-export-failed.xd (29.5 KB) I’m using xd.createRenditions([ params ]). As pdf doesn’t have any options, params object is the same as in the documentation.
Are there any workarounds for that?

XD version 36.2.32.5 on Windows but also reproduceable on Mac.

Can you show clarify what you mean by “empty folder next to the item”? Is the empty folder a sibling of the file you’re exporting, or the parent?

I attached document to reproduce the issue. Empty folder I mean folder in document layers structure. And it’s a sibling for the layer marked for export.
Export works if I export layer using XD UI but doesn’t work if I do the same using XD API.

Oh – I thought you meant a folder on the file system. D’oh!

@DavidXD ^^^ Ideas?

I was able to reproduce this problem with the XD UI as well. Looks like there is a bug with PDF export in this situation. I let our team know. Thanks for telling us about it!

1 Like

A developer looked at this and discovered that this error occurs when the PDF export is attempting to act on something that is too small to be rendered visually. He fixed it so that instead of failing, XD will simply ignore those paths. The fix is currently scheduled for XD 39. Thanks again for your bug report!

1 Like