question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

v1.3.3 and v1.3.4 is not compatible with py38/py39

See original GitHub issue

Despite the fact that Cerberus==1.3.4 list compatibility with py39 we can easily get:

.tox/py39/lib/python3.9/site-packages/cerberus/validator.py:19: in <module>
    from cerberus import errors
E     File "/Users/ssbarnea/c/a/molecule/.tox/py39/lib/python3.9/site-packages/cerberus/errors.py", line 156
E       """
E       ^
E   SyntaxError: invalid escape sequence \*

While this bug was fixed in master it is not of any help for consumers of the library as there is no newer release. Even a pre-release like 2.0.0a0 could help as it would allow us to request it when running on py39 in setup.cfg.

Another approach would be backporting the fixed and making another hotfix release.

Issue Analytics

  • State:open
  • Created 2 years ago
  • Comments:13 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
tadeborocommented, May 18, 2021

@funkyfuture Are you running flake8 from the repo? The invalid escape sequence will not be reported there because the tox.ini file instructs flake8 to ignore that error: https://github.com/pyeve/cerberus/blob/a70b404e5bf164bb6eaf1d7f264957db4ab7d55c/tox.ini#L28

That change was introduced in https://github.com/pyeve/cerberus/commit/e2c5620ad88e8e3f20edadb66d2c60793b44d338#diff-ef2cef9f88b4fe09ca3082140e67f5ad34fb65fb6e228f119d3812261ae51449, but I cannot find the reason behind the addition of that ignore entry.

0reactions
tadeborocommented, May 23, 2021

The invalid escape sequence warning is silenced by default because it would annoy people maintaining ancient codebases written when those escape sequences were valid. Python interpreted them as literal backslash plus whatever comes after it. But “THe Right Way ™” that Python devs suggest here is to either use raw string literals or escape the backslash.

Read more comments on GitHub >

github_iconTop Results From Across the Web

No results found

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found