Open connorworley opened 4 years ago
Does this drawing have linked documents in it? You might need to pass in the LinkDocumentId and the LinkDocumentWorkspaceId. I'm guessing this has something to do with how the missing parts are pulled in. Let me know what you find!
I don't think I have linked documents (my Onshape experience is very limited). Here's what I'm working with: https://cad.onshape.com/documents/c7d69482982a4c651d6d46f9/w/5ffe3a8df402271b05556d03/e/a3fb83a45863d8b3a5c10c86
Has there been a solution to the problem in the meantime?
I just tested this again and the drawing now seems to be correct. If anyone can repro then I can close this issue.
I'm running into a strange issue when I try to create PDF translations of drawings using the API.
Drawings through the browser look fine: browser.pdf But drawings through the API have missing views: api.pdf
Here's my code to generate the drawing through the API.
I've inspected the request that my browser makes when exporting a drawing, and the request the Python client makes by setting
onshape_client.client.Client.get_client().configuration.debug = True
.After some experimentation, it looks like the PDF only comes out normal when certain headers in the browser request are present.
/api/documents/d/c7d69482982a4c651d6d46f9/w/5ffe3a8df402271b05556d03/translate
/api/drawings/d/c7d69482982a4c651d6d46f9/w/5ffe3a8df402271b05556d03/e/5ab568ba4a2cc4a3d8171f1a/translations
Is this expected behavior? Any possible workarounds?