Skip to content
This repository was archived by the owner on Jun 24, 2023. It is now read-only.
This repository was archived by the owner on Jun 24, 2023. It is now read-only.

U flag to open causing a python-3.11 failure, aka are you continuing snake? #33

@abadger

Description

@abadger

Hey, I'm wondering if you are going to continue working on snake. I just upgraded to 3.11 and noticed that changes to open() (the "U" flag has gone away) is causing a failure:

Error invoking 'python_execute_file' on channel 3 (python3-script-host):
Traceback (most recent call last):
  File "/home/badger/.vim/pack/badger/start/snake/plugin/bootstrap.py", line 11, in <module>
    import snake
  File "/home/badger/.vim/pack/badger/start/snake/plugin/snake/__init__.py", line 737, in <module>
    from . import plugin_loader
  File "/home/badger/.vim/pack/badger/start/snake/plugin/snake/plugin_loader.py", line 215, in <module>

    import_source("vimrc", vimrc_path)
  File "/home/badger/.vim/pack/badger/start/snake/plugin/snake/plugin_loader.py", line 206, in import_s
ource
    h = open(path, desc[1])
        ^^^^^^^^^^^^^^^^^^^
ValueError: invalid mode: 'U'

If you're going to continue work on snake, I can look at opening a PR to omit the flag when we are using later python versions. There are other deprecations in the works, though (for instance, imp is deprecated) so I'll probably try porting my configs to lua if you don't have time to keep snake updated anymore.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions