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

Fix frequent LookupError exceptions #282

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ watchdog = {extras = ["watchmedo"], version = "*"}
djangorestframework = "~=3.15.2"
django-environ = "~=0.4"
django-model-utils = "~=4.0"
sentry-sdk = "~=2.8.0"
sentry-sdk = "~=1.45.1"
typed-ast = "~=1.4.2"
mohawk = ">=1.1"
python-dateutil = "~=2.8"
Expand Down
21 changes: 10 additions & 11 deletions Pipfile.lock

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

2 changes: 0 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,5 @@ services:
container_name: hmrc-redis
expose:
- 6379
ports:
- 6379:6379
Comment on lines -81 to -82
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can I ask what this change does?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

actually nvm I just read your commit messages which answered my question

volumes:
maildata:
2 changes: 1 addition & 1 deletion mail/libraries/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,7 @@ def sort_dtos_by_date(input_dtos):

def log_to_sentry(message, extra=None, level="info"):
extra = extra or {}
with sentry_sdk.new_scope() as scope:
with sentry_sdk.push_scope() as scope:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see that this is what we had before (https://github.com/uktrade/lite-hmrc/pull/274/files) so am I right to infer that the main change for this PR that we think will solve the issue is the version downgrade to 1.x ?

for key, value in extra.items():
scope.set_extra(key, value)
sentry_sdk.capture_message(message, level=level)
Expand Down
15 changes: 0 additions & 15 deletions mail/tests/libraries/test_helpers.py

This file was deleted.