mabuchilab / Instrumental

Python-based instrumentation library from the Mabuchi Lab.
http://instrumental-lib.readthedocs.org/
GNU General Public License v3.0
123 stars 80 forks source link

Remove "U" mode from from_file's open() for 3.12 compatability. #171

Open mcshlanta opened 2 months ago

mcshlanta commented 2 months ago

The U file mode tells Python to read the file in "universal newlines" mode. This has been the default as of Python 3.0 and should be controlled from the newline keyword parameter which deprecated the U mode specifier.

U was removed in Python 3.12 and now causes a ValueError if used.