-
Notifications
You must be signed in to change notification settings - Fork 1k
lint: fix typos and include lint checking #18553
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
base: main
Are you sure you want to change the base?
Changes from all commits
db9c123
56939a7
64eefcb
1d77240
3f782ab
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
codespell | ||
djlint | ||
flake8 | ||
flake8-pytest-style | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -129,7 +129,7 @@ def test_send(self, sender_class): | |
service = sender_class(mailer, sender="DevPyPI <[email protected]>") | ||
|
||
service.send( | ||
"sombody@example.com", | ||
"somebody@example.com", | ||
EmailMessage( | ||
subject="a subject", body_text="a body", body_html="a html body" | ||
), | ||
|
@@ -142,7 +142,7 @@ def test_send(self, sender_class): | |
assert msg.subject == "a subject" | ||
assert msg.body == "a body" | ||
assert msg.html == "a html body" | ||
assert msg.recipients == ["sombody@example.com"] | ||
assert msg.recipients == ["somebody@example.com"] | ||
assert msg.sender == "DevPyPI <[email protected]>" | ||
|
||
def test_last_sent(self, sender_class): | ||
|
@@ -160,7 +160,7 @@ def test_send(self, capsys): | |
) | ||
|
||
service.send( | ||
"sombody@example.com", | ||
"somebody@example.com", | ||
EmailMessage( | ||
subject="a subject", | ||
body_text="a body", | ||
|
@@ -172,7 +172,7 @@ def test_send(self, capsys): | |
Email sent | ||
Subject: a subject | ||
From: DevPyPI <[email protected]> | ||
To: sombody@example.com | ||
To: somebody@example.com | ||
HTML: Visualize at http://localhost:1080 | ||
Text: a body""" | ||
assert captured.out.strip() == expected.strip() | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -128,7 +128,7 @@ def test_lookup_actor_404(self, monkeypatch): | |
) | ||
requests = pretend.stub( | ||
post=pretend.call_recorder(lambda o, **kw: response), | ||
expception=_requests.exceptions, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. seems odd to me that this doesn't change the behavior of this test There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks for noting. Looks like the assertions never care about this specific property, so I can remove these from being set, if they have no impact. I'll remove them completely in a following commit. |
||
exception=_requests.exceptions, | ||
Timeout=Timeout, | ||
HTTPError=HTTPError, | ||
ConnectionError=ConnectionError, | ||
|
@@ -160,7 +160,7 @@ def test_lookup_actor_other_http_error(self, monkeypatch): | |
) | ||
requests = pretend.stub( | ||
post=pretend.call_recorder(lambda o, **kw: response), | ||
expception=_requests.exceptions, | ||
exception=_requests.exceptions, | ||
Timeout=Timeout, | ||
HTTPError=HTTPError, | ||
ConnectionError=ConnectionError, | ||
|
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.
I am -1 on this. seems it could be a footgun if an undesirable change to spelling is automatically written.
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.
Happy to remove, whenever there is an ambiguity of spelling, codespell won't change it, rather continue to error out during a lint phase.
Happy to remove if you think this is a serious footgun, but otherwise it felt appropriate to help the user similar to other reformat directives.