-
-
Notifications
You must be signed in to change notification settings - Fork 533
Dont pass around re match object #1712
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
Dont pass around re match object #1712
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
CI needs to pass
The CI failure here is #1699 (comment) This PR also needs doc amendments IMO, as described on #1711 |
src/tox/config/__init__.py
Outdated
|
||
try: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
#1715 is the prefered approach for this chunk.
I'll rebase after that is merged, assuming it is accepted.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rebased; im ambivalent about whether this is merged or not. Also it feels odd writing a changelog entry for this. I'd be fine with slipping this into another PR to avoid it being a standalone changelog entry.
f8e4617
to
0308a15
Compare
docs/changelog/1712.misc.rst
Outdated
@@ -0,0 +1 @@ | |||
Do not pass around regex match object in Replacer. - by :user:`jayvdb` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only user-facing changes need changelog.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
great. But wont CI fail if this file doesnt exist?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The check will fail but that's not mandatory for merge. You can add some naming of the title too to skip it I think 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
0308a15
to
bdd4dac
Compare
Removes dead code and keep the match object within
Replacer._replace_match
, adding explicit args to the other private methods ofReplacer
so they are clearer.Related to #1711
Contribution checklist:
(also see CONTRIBUTING.rst for details)
in message body
<issue number>.<type>.rst
for example (588.bugfix.rst)<type>
is must be one ofbugfix
,feature
,deprecation
,breaking
,doc
,misc
<your username>
"superuser
."CONTRIBUTORS
(preserving alphabetical order)