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.

Author opensource-assist
Recipients opensource-assist
Date 2020-01-27.19:46:52
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1580154412.97.0.35138425226.issue39468@roundup.psfhosted.org>
In-reply-to
Content
On a typical Linux system, if you run 'chattr +i /home/user/.python_history', and then run python, then exit, the following error message will be printed out:
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/site.py", line 446, in write_history
    readline.write_history_file(history)
OSError: [Errno -1] Unknown error -1


With a simple improvement, the site module can check and suggest the user to run 'chattr -i' on the .python_history file.

Additionaly, I don't know if it's a good idea to automatically run 'chattr -i' in such a situation or not.
History
Date User Action Args
2020-01-27 19:46:53opensource-assistsetrecipients: + opensource-assist
2020-01-27 19:46:52opensource-assistsetmessageid: <1580154412.97.0.35138425226.issue39468@roundup.psfhosted.org>
2020-01-27 19:46:52opensource-assistlinkissue39468 messages
2020-01-27 19:46:52opensource-assistcreate