Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[python-3.11] open() - invalid mode 'rU' #30

Open
dreamcat4 opened this issue Aug 12, 2023 · 1 comment
Open

[python-3.11] open() - invalid mode 'rU' #30

dreamcat4 opened this issue Aug 12, 2023 · 1 comment

Comments

@dreamcat4
Copy link

Things have changed in the latest python 3 release (3.11)...

[!] Something went wrong while reading firefox profiles.ini
ERROR:root:Traceback (most recent call last):
  File "/home/id/.builds/firefox/ExtAnalysis/core/localextensions.py", line 179, in firefox
    with open(firefox_profile, 'rU') as ini_source:
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^
ValueError: invalid mode: 'rU'

Here is some discussion about it Cantera/cantera#1325

@dreamcat4
Copy link
Author

The suggested solution seems to be:

Stop using deprecated flag U.... (Quote from stack*):

Since the 'rU' file read-mode is deprecated in python3 so you have to update that code to this. (Change rU to r)

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant