SyntaxWarning for escape sequence
I get the following syntax warning when running visualize.py:
/usr/local/share/isoquant-3.6.3-0/src/file_utils.py:25: SyntaxWarning: invalid escape sequence '\d'
The referenced line:
https://github.com/ablab/IsoQuant/blob/159f9af1d439a23d6161f67da95379874e0aafbe/src/file_utils.py#L25
should use a raw string literal:
re.split('r(\d+)', s)
Thanks for your help!
I can confirm that I'm encountering this error also, using versions 3.6.1 and 3.6.3
Thanks for the report, will fix in the next release!
Hi! Thanks so much for this amazing tool. I encountered the same issue while running nf-core/sc-nanoseq pipeline. Is there any way to get a singularity image with the fixed typo? https://biocontainers.pro/tools/isoquant Thank you so much!
Hi!
I will make a new release within the next week! Also, I think the error should be just a warning in earlier Python version.
P.S. I also suggest using the latest IsoQuant version.
Best Andrey
Thanks @andrewprzh : we will fix things on our end (in nf-core/scnanoseq) as soon as your new release is out.
thanks for looking into this!
For anyone curious
Other Language Changes
- A backslash-character pair that is not a valid escape sequence now generates a SyntaxWarning, instead of DeprecationWarning. For example, re.compile("\d+.\d+") now emits a SyntaxWarning ("\d" is an invalid escape sequence, use raw strings for regular expression: re.compile(r"\d+.\d+")). In a future Python version, SyntaxError will eventually be raised, instead of SyntaxWarning. (Contributed by Victor Stinner in gh-98401.)
https://docs.python.org/3/whatsnew/3.12.html#other-language-changes
Fixed in 3.7