omz:forum

    • Register
    • Login
    • Search
    • Recent
    • Popular

    Welcome!

    This is the community forum for my apps Pythonista and Editorial.

    For individual support questions, you can also send an email. If you have a very short question or just want to say hello — I'm @olemoritz on Twitter.


    Script can't copy anymore a file from iCloud Drive since iOS 11.4.1

    Pythonista
    1
    4
    2834
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • cvp
      cvp last edited by

      I had a script who copies a file from a folder of my iCloud Drive.

      fil = '/private/var/mobile/Library/Mobile Documents/com~apple~Numbers/Documents/Xxxx.numbers'
      shutil.copy(fil,local_path)
      

      I have updated my iPad to iOS to 11.4.1 and now I get an error during shutil.copy:

      PermissionError: [Errno 1] Operation not permitted: '/private/var/mobile/Library/Mobile Documents/com~apple~Numbers/Documents/Xxxx.numbers'
      
      1 Reply Last reply Reply Quote 0
      • cvp
        cvp last edited by

        Using

        	fil = dialogs.pick_document(types=['public.item'])
        

        works but needs an user intervention to select the file...

        1 Reply Last reply Reply Quote 0
        • cvp
          cvp last edited by

          To @omz is it possible to restrict to one file type by something like

          	fil = dialogs.pick_document(types=['com.apple.numbers.numbers'])
          

          Or even to only one file?

          1 Reply Last reply Reply Quote 0
          • cvp
            cvp last edited by cvp

            This restricts to .numbers files:

            fil = dialogs.pick_document(types=['com.apple.iwork.numbers.numbers'])
            
            1 Reply Last reply Reply Quote 0
            • First post
              Last post
            Powered by NodeBB Forums | Contributors