Skip to content
This repository has been archived by the owner on Jan 9, 2025. It is now read-only.

Fix: deprecated and now retired "universal newlines" mode #32

Open
tardate opened this issue Dec 29, 2024 · 0 comments
Open

Fix: deprecated and now retired "universal newlines" mode #32

tardate opened this issue Dec 29, 2024 · 0 comments

Comments

@tardate
Copy link

tardate commented Dec 29, 2024

I just tried out csv2md on Python 3.11.10.

It fails with the error:

Traceback (most recent call last):
  File "/opt/homebrew/bin/csvtomd", line 8, in <module>
    sys.exit(main())
             ^^^^^^
  File "/opt/homebrew/lib/python3.11/site-packages/csvtomd/csvtomd.py", line 149, in main
    with open(filename, 'rU') as f:
         ^^^^^^^^^^^^^^^^^^^^
ValueError: invalid mode: 'rU'

As I understand it, this is because the "universal newlines" mode ('rU') has been deprecated since Python 3.4 and completely removed in Python 3.11.

I haven't dug into the code yet to see if I can suggest a PR. First just wanted to ask if there is an appetite/intent to upgrade for newer python versions?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant