-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Meta: Allow adding date to Resolution header #4061
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
Merged
Merged
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
a4feace
Update pre-commit hook
JelleZijlstra d764a9d
Allow resolution date in Resolution header
JelleZijlstra 5b11bd6
remove pinrt
JelleZijlstra 45f2365
Allow message
JelleZijlstra 1e6029f
remove stray function
JelleZijlstra 1aca0a0
Add tests to increase coverage
hugovk File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -79,6 +79,20 @@ def test_validate_post_history_valid(body: str): | |
assert warnings == [], warnings | ||
|
||
|
||
@pytest.mark.parametrize( | ||
"body", | ||
[ | ||
"31-Jul-2015 <https://discuss.python.org/t/123456>`__,", | ||
"`31-Jul-2015 <https://discuss.python.org/t/123456>", | ||
], | ||
) | ||
def test_validate_post_history_unbalanced_link(body: str): | ||
warnings = [warning for (_, warning) in check_peps._validate_post_history(1, body)] | ||
assert warnings == [ | ||
"post line must be a date or both start with “`” and end with “>`__”" | ||
], warnings | ||
|
||
|
||
@pytest.mark.parametrize( | ||
"line", | ||
[ | ||
|
@@ -90,6 +104,7 @@ def test_validate_post_history_valid(body: str): | |
"https://mail.python.org/archives/list/[email protected]/message/abcXYZ123/#Anchor", | ||
"https://mail.python.org/archives/list/[email protected]/message/abcXYZ123#Anchor123", | ||
"https://mail.python.org/archives/list/[email protected]/message/abcXYZ123/#Anchor123", | ||
"`16-Oct-2024 <https://mail.python.org/archives/list/[email protected]/thread/abcXYZ123>`__", | ||
], | ||
) | ||
def test_validate_resolution_valid(line: str): | ||
|
@@ -117,6 +132,20 @@ def test_validate_resolution_invalid(line: str): | |
assert warnings == ["Resolution must be a valid thread URL"], warnings | ||
|
||
|
||
@pytest.mark.parametrize( | ||
"line", | ||
[ | ||
"01-Jan-2000 <https://mail.python.org/pipermail/list-name/0000-Month/0123456.html>`__", | ||
"`01-Jan-2000 <https://mail.python.org/pipermail/list-name/0000-Month/0123456.html>", | ||
], | ||
) | ||
def test_validate_resolution_unbalanced_link(line: str): | ||
warnings = [warning for (_, warning) in check_peps._validate_resolution(1, line)] | ||
assert warnings == [ | ||
"Resolution line must be a link or both start with “`” and end with “>`__”" | ||
], warnings | ||
|
||
|
||
@pytest.mark.parametrize( | ||
"thread_url", | ||
[ | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,7 +9,7 @@ Created: 30-Dec-2022 | |
Python-Version: 3.13 | ||
Post-History: `01-Jan-2023 <https://mail.python.org/archives/list/[email protected]/thread/AKTFUYW3WDT7R7PGRIJQZMYHMDJNE4QH/>`__, | ||
`22-Jan-2023 <https://discuss.python.org/t/pep-702-marking-deprecations-using-the-type-system/23036>`__ | ||
Resolution: https://discuss.python.org/t/pep-702-marking-deprecations-using-the-type-system/23036/61 | ||
Resolution: `07-Nov-2023 <https://discuss.python.org/t/pep-702-marking-deprecations-using-the-type-system/23036/61>`__ | ||
|
||
.. canonical-typing-spec:: :ref:`typing:deprecated` and | ||
:external+py3.13:func:`@warnings.deprecated<warnings.deprecated>` | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.