Skip to content

Commit

Permalink
Merge branch 'main' into upsert-tags-in-three-queries
Browse files Browse the repository at this point in the history
  • Loading branch information
jb3 authored Apr 2, 2024
2 parents 084b52b + ad60d02 commit 996353e
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 20 deletions.
38 changes: 19 additions & 19 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions pydis_site/apps/api/tests/test_github_webhook_filter.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import io
from unittest import mock
from urllib.error import HTTPError

Expand Down Expand Up @@ -58,6 +59,7 @@ def test_rate_limit_is_logged_to_sentry(self):
mock.patch.object(GitHubWebhookFilterView, "logger") as logger,
):
urlopen.side_effect = HTTPError(None, 429, 'Too Many Requests', {}, None)
urlopen.side_effect.fp = io.BytesIO()
logger.warning = mock.PropertyMock()
self.client.post(url, data=payload, headers=headers)

Expand All @@ -72,6 +74,7 @@ def test_other_error_is_logged(self):
mock.patch.object(GitHubWebhookFilterView, "logger") as logger,
):
urlopen.side_effect = HTTPError(None, 451, 'Unavailable For Legal Reasons', {}, None)
urlopen.side_effect.fp = io.BytesIO()
logger.warning = mock.PropertyMock()
self.client.post(url, data=payload, headers=headers)

Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ psycopg = {extras = ["binary"], version = "3.1.18"}
[tool.poetry.group.dev.dependencies]
python-dotenv = "1.0.1"
taskipy = "1.12.2"
ruff = "0.3.4"
ruff = "0.3.5"

[tool.poetry.group.lint.dependencies]
pre-commit = "3.7.0"
Expand Down

0 comments on commit 996353e

Please sign in to comment.