-
Notifications
You must be signed in to change notification settings - Fork 6
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
Clean logging and sentry logging setup #4611
base: develop
Are you sure you want to change the base?
Conversation
Codecov ReportAttention: Patch coverage is
❌ Your patch check has failed because the patch coverage (31.88%) is below the target coverage (95.00%). You can increase the patch coverage or adjust the target coverage. Additional details and impacted files@@ Coverage Diff @@
## develop #4611 +/- ##
========================================
Coverage 86.13% 86.13%
========================================
Files 566 566
Lines 36815 36815
========================================
Hits 31711 31711
Misses 5104 5104
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
# Conflicts: # src/hct_mis_api/apps/payment/services/payment_gateway.py # src/hct_mis_api/apps/targeting/validators.py # src/hct_mis_api/one_time_scripts/migrate_rdi_deduplication_stats.py
@@ -0,0 +1,67 @@ | |||
import logging | |||
|
|||
from hct_mis_api.apps.household.models import ( |
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.
what's this?
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.
it looks like some merge bring me that, I will remove it from my pr
This pull request includes several changes to improve the logging level across various functions in the codebase. The primary change involves replacing
logger.exception
andlogger.error
withlogger.warning
to adjust the severity of the logged messages.Changes to logging levels:
src/hct_mis_api/apps/account/admin/ad.py
: Changed logging level fromlogger.exception
tologger.warning
in multiple functions to reduce the severity of log messages. [1] [2] [3]src/hct_mis_api/apps/account/admin/filters.py
: Updated logging fromlogger.exception
tologger.warning
in thequeryset
method.src/hct_mis_api/apps/account/admin/forms.py
: Adjusted logging level fromlogger.error
tologger.warning
in theclean_emails
method.src/hct_mis_api/apps/account/admin/mixins.py
: Modified logging level fromlogger.exception
tologger.warning
in several functions to better reflect the severity of the messages. [1] [2] [3] [4] [5] [6]src/hct_mis_api/apps/account/admin/user.py
: Changed logging fromlogger.exception
tologger.warning
in theimport_csv
method.src/hct_mis_api/apps/account/authentication.py
: Updated logging level fromlogger.error
tologger.warning
in therequire_email
method.src/hct_mis_api/apps/account/microsoft_graph.py
: Adjusted logging fromlogger.exception
andlogger.error
tologger.warning
in multiple functions. [1] [2]src/hct_mis_api/apps/account/models.py
: Changed logging level fromlogger.error
tologger.warning
in various validation methods. [1] [2] [3]src/hct_mis_api/apps/accountability/celery_tasks.py
: Modified logging fromlogger.exception
tologger.warning
in theexport_survey_sample_task
function.src/hct_mis_api/apps/accountability/services/message_crud_services.py
: Updated logging fromlogger.error
tologger.warning
in thecreate
method.src/hct_mis_api/apps/accountability/services/verifiers.py
: Adjusted logging fromlogger.error
tologger.warning
in theverify
method. [1] [2]src/hct_mis_api/apps/administration/panels/email.py
: Changed logging fromlogger.exception
tologger.warning
in theemail
method.src/hct_mis_api/apps/administration/panels/es.py
: Updated logging fromlogger.exception
tologger.warning
in the__call__
method.src/hct_mis_api/apps/core/admin.py
: Modified logging fromlogger.exception
tologger.warning
in multiple functions. [1] [2]src/hct_mis_api/apps/core/attributes_qet_queries.py
: Adjusted logging fromlogger.error
tologger.warning
in various query methods. [1] [2] [3]src/hct_mis_api/apps/core/celery_tasks.py
: Changed logging fromlogger.error
tologger.exception
in thewrapper_func
method to ensure full stack trace logging for exceptions.