regro / rever

Releaser of Versions
https://regro.github.io/rever-docs/
BSD 3-Clause "New" or "Revised" License
75 stars 33 forks source link

invalid escape sequences #172

Open djsutherland opened 5 years ago

djsutherland commented 5 years ago

In Python 3.7, I get:

$ rever --help
<unknown>:1: DeprecationWarning: invalid escape sequence \w
<unknown>:1: DeprecationWarning: invalid escape sequence \s
<unknown>:1: DeprecationWarning: invalid escape sequence \*
/nfs/nhome/live/dougals/miniconda/envs/py3/lib/python3.7/site-packages/socks.py:58: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated, and in 3.8 it will stop working
  from collections import Callable
/nfs/nhome/live/dougals/miniconda/envs/py3/lib/python3.7/site-packages/github3/structs.py:11: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated, and in 3.8 it will stop working
  class GitHubIterator(models.GitHubCore, collections.Iterator):
<unknown>:32: DeprecationWarning: invalid escape sequence \s
usage: rever [-h] [--rc RC] [-a ACTIVITIES] [-u UNDO] [-e ENTRYPOINT] [-f]
[...]

The socks/github3 warnings of course aren't rever's fault, but probably there are some bare strings that should be raw strings around.

scopatz commented 5 years ago

Which version of rever and xonsh are you on? I thought we got rid of a lot of these on the latest release

djsutherland commented 5 years ago

Happens eg with rever 0.3.1-py37_0, xonsh 0.8.8-py37_0 on Mac.

scopatz commented 5 years ago

Yeah, I think these were fixed in 0.3.2 https://regro.github.io/rever-docs/changelog.html#v0-3-2

kcpevey commented 4 years ago

I'm following the instructions on the main page of docs and running rever setup. I'm getting

<unknown>:1: DeprecationWarning: invalid escape sequence \s

rever 0.4.4 xonsh 0.9.19

scopatz commented 4 years ago

@kcpevey - That is from your rever.xsh, probably in the version bump patterns.

scopatz commented 4 years ago

You just need to make the strings raw, eg r"...\s..."

kcpevey commented 4 years ago

Thanks! That fixed it. The docs should be updated. This is what led me astray: https://regro.github.io/rever-docs/index.html#initializing-rever

scopatz commented 4 years ago

Yep! Will do.