Post

Replies

Boosts

Views

Activity

Reply to Run python script from the App Sandbox
Lol, for me it is required, as I am building RegExp testing utility (https://apps.apple.com/us/app/regexp/id1546140065) for various languages. Implementations in languages have slight differences, so the best ways to implement flavors is to use the original languages. Right now I have: Swift/Objc with NSRegularExpression Go (that was easy, considering I can build a CLI and just embed it in the Helpers as CLI tool) JavaScript (with WebKit embedded) For Python/Ruby, etc I don't want to **** the application itself, and want to use shipped with Mac Python runtimes. So back to my question, when I try to launch a process with let task = Process() task.executableURL = "/usr/bin/python3" task.arguments = [[URL(fileURLWithPath: "python.py", relativeTo: Bundle.main.resourceURL).path]] ... I get xcrun: error: cannot be used within an App Sandbox So my original question is, my guess if that is possible to do with App Sandbox, I need to: give some additional capabilities? maybe ask user to point to the Python and have "read-only" access to the file (but that would not give execution permission on the file) I will appreciate any pointers to what to try, what to read.
Dec ’20