Python Open and Close Desktop connector txt file

Hi All

This workflow was working a few moths ago .

I was opening and closing files from Desktop Connector to force them syncing.

Python code below.

`file = open(path,“r”)

file.close()`

It doesn’t work anymore. Something changed in desktop connector (I’m using 14.11.0.1476) ?

Any other way to achieve that ?

Thanks!

Should work - what is the error you are getting? Note that the paths changed somewhere around v12 to incorporate the change from BIM360 to Autodesk Docs.

@jacob.small there is no error. I have the code in a try-except block and the open file is executed. I have the correct new path. They file in the desktop connector is not synced though.

I am unable to reproduce… might be a cloud side delay or a concurrent access issue.

Can you force sync in DTX?

It may be worth looking into the API options.

It works if I manually double click on the file.

image.

So it’s working on your end using Python ? The file goes from Online to Synced ?

what API options ?

Yes - that method is working for me (and as far as I know others as well).

The application has an API which I have popped open to do some stuff. There is no documentation, ensured or implied stability or consistency with it so it’s a bit of a dig to make it work.

Greetings,
Im having this issue as well. Did you have any luck getting the file to sync with python?