Skip to content
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

[3.8] bpo-32912: Revert warnings for invalid escape sequences. #15142

Merged
merged 3 commits into from Aug 9, 2019

Conversation

@serhiy-storchaka
Copy link
Member

commented Aug 6, 2019

DeprecationWarning will continue to be emitted for invalid
escape sequences in string and bytes literals in 3.8.
SyntaxWarning will be emitted in 3.9.

https://bugs.python.org/issue32912

bpo-32912: Revert warnings for invalid escape sequences.
DeprecationWarning will continue to be emitted for invalid
escape sequences in string and bytes literals in 3.8.
SyntaxWarning will be emitted in 3.9.
update the wording to not promise 3.9
and mention that SyntaxError will happen after SyntaxWarning.  we're being non-specific on purpose here as we haven't worked out the plan to make this happen without causing end user pain yet.  right now most code owners do not see the DeprecationWarning but when turned into a SyntaxWarning, _users_ of libraries see it more often than owners.  So it is a negative experience all around.
@gpshead

gpshead approved these changes Aug 8, 2019

@gpshead

This comment has been minimized.

Copy link
Member

commented Aug 8, 2019

My only problem with this PR is only that it is being done on the 3.8 branch.

We should revert this on the master (future 3.9) branch as well. We clearly aren't ready to commit to doing this in 3.9 either so lets redo this on top of that and apply the "needs backport to 3.8" label.

@CuriousLearner
Copy link
Contributor

left a comment

I tend to agree with @gpshead on applying this to master and then backporting to 3.8

@gpshead gpshead merged commit 4c5b6ba into python:3.8 Aug 9, 2019

6 checks passed

Azure Pipelines PR #20190808.25 succeeded
Details
bedevere/issue-number Issue number 32912 found
Details
bedevere/maintenance-branch-pr Valid maintenance branch PR title.
bedevere/news News entry found in Misc/NEWS.d
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@gpshead

This comment has been minimized.

Copy link
Member

commented Aug 9, 2019

merged. I'll just reapply an equivalent to master.

miss-islington added a commit that referenced this pull request Aug 10, 2019

bpo-32912: Revert SyntaxWarning on invalid escape sequences. (GH-15195)
DeprecationWarning will continue to be emitted for invalid escape
sequences in string and bytes literals just as it did in 3.7.

SyntaxWarning may be emitted in the future. But per mailing list
discussion, we don't yet know when because we haven't settled on how to
do so in a non-disruptive manner.

(Applies 4c5b6ba to the master branch).
(This is #15142 for master/3.9)


https://bugs.python.org/issue32912



Automerge-Triggered-By: @gpshead

LorenzMende added a commit to LorenzMende/cpython that referenced this pull request Aug 11, 2019

bpo-32912: Revert SyntaxWarning on invalid escape sequences. (pythonG…
…H-15195)

DeprecationWarning will continue to be emitted for invalid escape
sequences in string and bytes literals just as it did in 3.7.

SyntaxWarning may be emitted in the future. But per mailing list
discussion, we don't yet know when because we haven't settled on how to
do so in a non-disruptive manner.

(Applies 4c5b6ba to the master branch).
(This is python#15142 for master/3.9)


https://bugs.python.org/issue32912



Automerge-Triggered-By: @gpshead
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
7 participants
You can’t perform that action at this time.