This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: [Errno 1]
Type: Stage: resolved
Components: Versions:
process
Status: closed Resolution:
Dependencies: Superseder:
Assigned To: Nosy List: TotallyLost, remi.lapeyre
Priority: normal Keywords:

Created on 2020-05-16 20:09 by TotallyLost, last changed 2022-04-11 14:59 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
errormessage.jpg TotallyLost, 2020-05-16 23:23
Messages (9)
msg369065 - (view) Author: Glenn Travis (TotallyLost) Date: 2020-05-16 20:09
A fellow on the X-Plane forum reported getting this:

cd desktop/Ortho4XP-130

ianrobertson@Ians-iMac Ortho4XP-130 % python3 Ortho4XP_v130.py

/Library/Frameworks/Python.framework/Versions/3.8/bin/python3: can't open file 'Ortho4XP_v130.py': [Errno 1] Operation not permitted

he is able to run python3.8.2 from the terminal and get it to work with the interpreter for a print('Howdy') but Ortho4Xp not.

is this a python thing, an ortho thing or some root cause from installing python?
msg369068 - (view) Author: Rémi Lapeyre (remi.lapeyre) * Date: 2020-05-16 20:55
Hi Glenn, this is probably not a bug in Python and more information about the error and the context would be needed if it was. Bugs must be reproducible to be looked at and fixed and your post does not contain enough information to do so.

You should redirect your friend to a forum like StackOverflow or the python-help mailing list to get help with his script.
msg369080 - (view) Author: Glenn Travis (TotallyLost) Date: 2020-05-16 23:21
I think that there is something odd going on with his python install.
He just tried to run a very simple python script that I made for him,

print('Hello there python interperter')

And he got the same error message again.  I do not know what more information you need, I sent the copy and paste terminal error text.
msg369081 - (view) Author: Glenn Travis (TotallyLost) Date: 2020-05-16 23:30
I think that I will ask him to reinstall Python. Which can be a scary process for him.
msg369110 - (view) Author: Rémi Lapeyre (remi.lapeyre) * Date: 2020-05-17 10:51
The error message you linked does not show an issue with the Python installation but the permissions are wrong on the 'howdy.py' file, that's what the error message says:

    can't open file 'howdy.py': [Errno 1] Operation not permitted

You have to check the permissions on the file to make sure the Python interpreter can read it.

This is not a bug in the Python interpreter which this bug tracker is for, the python-help mailing list and StackOverflow will give you the help you are looking for.
msg369117 - (view) Author: Glenn Travis (TotallyLost) Date: 2020-05-17 12:50
ok, fine.
So what permissions would indicate that "the Python interpreter can read it."
The Get Info screenshot that he sent me looks just like mine with regard to permissions. The long list in terminal shows nothing special. 

I am not having problems running the scripts.
msg369118 - (view) Author: Glenn Travis (TotallyLost) Date: 2020-05-17 13:04
As per your suggestion I have sent an email to python help, just looking for info regarding what you would consider the key permission settings.
msg369121 - (view) Author: Rémi Lapeyre (remi.lapeyre) * Date: 2020-05-17 13:39
It's because application on recent versions of MacOS cannot access files in some directories without being granted permission explicitly, a permission model similar to what iOS and Android.

You can grant them additional permission using System Preferences, see https://osxdaily.com/2018/10/09/fix-operation-not-permitted-terminal-error-macos/ for example. All applications on recent version of MacOS behaves like this and this is not a bug in Python.
msg369126 - (view) Author: Glenn Travis (TotallyLost) Date: 2020-05-17 15:08
I think that you are referring to Gatekeeper.  Something that I have run into with various applications, such as certain utility files in Ortho4XP and even when adding aircraft to X-Plane(some of the developers refuse to become approved Apple developers).
History
Date User Action Args
2022-04-11 14:59:31adminsetgithub: 84829
2020-05-17 15:08:30TotallyLostsetstatus: open -> closed

messages: + msg369126
stage: resolved
2020-05-17 13:39:42remi.lapeyresetmessages: + msg369121
2020-05-17 13:04:38TotallyLostsetmessages: + msg369118
2020-05-17 12:50:21TotallyLostsetmessages: + msg369117
2020-05-17 10:51:10remi.lapeyresetmessages: + msg369110
2020-05-16 23:30:32TotallyLostsetmessages: + msg369081
2020-05-16 23:23:34TotallyLostsetfiles: + errormessage.jpg
2020-05-16 23:21:07TotallyLostsetmessages: + msg369080
2020-05-16 20:55:43remi.lapeyresetnosy: + remi.lapeyre
messages: + msg369068
2020-05-16 20:11:13TotallyLostsettitle: [Errno 1} -> [Errno 1]
2020-05-16 20:09:24TotallyLostcreate