taskwarrior icon indicating copy to clipboard operation
taskwarrior copied to clipboard

Invalid escape sequences in tests

Open felixschurk opened this issue 1 year ago • 4 comments

When running the python tests, warnings about invalid escape sequences, as in #3316 do appear all over the place.

SyntaxWarning: invalid escape sequence

In order to fix them, one can prefix the corresponding string with an r to have it as a raw string. Probably this corresponds with the used Python version, which is currently under Fedora 40 Python 3.12.2.

felixschurk avatar Apr 22 '24 19:04 felixschurk

Huh, did we just fix a few of these in #3322 and miss the rest?

djmitche avatar Apr 22 '24 23:04 djmitche

I am pretty sure that it corresponds to the change to out-of-source build #3271, I am really sorry for missing that part. So as only the ones in problems was reported I only fixed them there.

Now while working with the test I realized (especially after also seeing the invalid escape) that unfortunately we dropped all the integration python tests with this change. (Due to not updated, copied python tests as in #3387 and the corresponding issue.

When one does look up the commit history and the corresponding unit test one can see that here around 3800 tests where run and then in this run only 2700.

felixschurk avatar Apr 23 '24 03:04 felixschurk

Oops! That certainly does make things run faster though :)

djmitche avatar Apr 23 '24 18:04 djmitche

For reference e.g. in the log file from this run one can see all the additional missing escape sequences.

felixschurk avatar Apr 28 '24 20:04 felixschurk