• surg30n

    @cvp Thanks for approvement. Thought, maybe there is some appropriate method to copy file from cloud, and simple copy is not allowed in widget from the security pose, but it seems not.

    posted in Pythonista read more
  • surg30n

    @cvp yes. It copies as in example above.
    File exists in cloud for sure.

    posted in Pythonista read more
  • surg30n

    @cvp no.. script a bit bigger. I write my own quotes to quote-file, separately. Script just gets random one and prints it. So it does it in a widget too as a console output (I added that script to widget).

    Just, if script tries get the random line from the quotes-file residing in icloud, it succeeds when I run it from IDE but fails when it runs in widget. ‘Access denied’. (BTW script in widget runs itself every time when i open widgets screen or when it on left side in IOS13 always-on).

    This small example here is just to show, how, f.e. Script copies quote-file from local storage to icloud. It works from IDE but fails when running in widget. Just gives out ‘access denied’ referring to icloud

    posted in Pythonista read more
  • surg30n

    Hey,

    icloud_path="/private/var/mobile/Library/Mobile Documents/iCloud~com~omz-software~Pythonista3/Documents/"
    quotes_file_name="my_quotes.txt";
    #Sync to iCloud;
    copyfile(icloud_path+quotes_file_name, current_path+quotes_file_name);
    
    

    Example code works from Pythonista IDE, but script has no access from widget.
    Maybe someone can direct me to some source making it right ? Or not possible to do it ?

    Thanks

    posted in Pythonista read more

Internal error.

Oops! Looks like something went wrong!