-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Python 3.12: Syntax warnings for escape sequences #1500
Comments
I hit the same issue. |
Thanks for the fix. Please update to the latest version |
Sorry @lpil : I didn't provide a fix for this one (it'll probably require a complete review of the Ultisnips snippets). |
I create one pr to fix this issue @ https://github.com/zhuzhzh/vim-snippets |
Thank you |
sionleroux
added a commit
to sionleroux/vimrc
that referenced
this issue
Sep 6, 2024
Critically, the update to the honza/vim-snippets repo fixes a character encoding issue that was constantly spamming while using snippets. Luckily I found the issue on GitHub, it's pretty recent[1], otherwise I was gearing up to switch to neosnippets, nothing wrong with it, it might even be better, cool, modern async stuff, but it's not what's in my muscle memory. [1]: honza/vim-snippets#1500
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
With Python 3.12, invalid escape sequences throw SyntaxWarnings instead of Deprecation warnings:
So, I think the regular expressions that we use in our snippets need to either be tweaked, or converted to raw strings which is probably easier. Otherwise, I get such warnings (with YouCompleteMe):
No such warnings are received on Python <= 3.11.
Expected behavior:
No warnings
Actual behavior:
Warnings related to escape sequences.
Steps to reproduce
vim -u <path to vimrc> -c :PlugInstall
vim -u <path to vimrc> test.java
i
. Type a letter, likep
. View error message at bottom, or use:messages
.Operating System: : Fedora 39
Vim Version: VIM - Vi IMproved 9.0 (2022 Jun 28, compiled Sep 05 2023 00:00:00); Included patches: 1-1872
UltiSnips Version: Ultisnips: SirVer/ultisnips@24a3ebb , vim-snippets: ccc2fa1
Python inside Vim: 3.12.0rc3 (main, Sep 19 2023, 00:00:00) [GCC 13.2.1 20230728 (Red Hat 13.2.1-1)]
Docker repo/vimrc:
The text was updated successfully, but these errors were encountered: