Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

open() mode 'rU' invalid mode #188

Closed
gruenbergera opened this issue Jan 9, 2023 · 1 comment · Fixed by #190
Closed

open() mode 'rU' invalid mode #188

gruenbergera opened this issue Jan 9, 2023 · 1 comment · Fixed by #190
Assignees

Comments

@gruenbergera
Copy link

Hello,

It looks like on line 480 of AnnotatorCore.py, open(eventfile, 'rU'), the mode for open() is set as rU. I believe python 3.11+ no longer has U as one of the valid modes, which causes some run time issues as is (if you're using 3.11 and newer, of course).

open()](https://docs.python.org/3/library/functions.html#open), io.open(), codecs.open() and fileinput.FileInput no longer accept 'U' (“universal newline”) in the file mode. In Python 3, “universal newline” mode is used by default whenever a file is opened in text mode, and the 'U' flag has been deprecated since Python 3.3. The newline parameter to these functions controls how universal newlines work. (Contributed by Victor Stinner in bpo-37330.)

https://docs.python.org/3/whatsnew/3.11.html#porting-to-python-3-11

In any case, whether this is a real issue or not, I appreciate the great work your organization contributes to the research community.

@zhx828
Copy link
Member

zhx828 commented Jan 9, 2023

Thank you! We will look into.

@zhx828 zhx828 self-assigned this Jan 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants