chore: Add additional log messages to directauth()#7716
Merged
rjsparks merged 2 commits intoietf-tools:mainfrom Jul 21, 2024
microamp:chore/directauth-logging
Merged
chore: Add additional log messages to directauth()#7716rjsparks merged 2 commits intoietf-tools:mainfrom microamp:chore/directauth-logging
rjsparks merged 2 commits intoietf-tools:mainfrom
microamp:chore/directauth-logging
Conversation
jennifer-richards
previously approved these changes
Jul 20, 2024
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #7716 +/- ##
=======================================
Coverage 88.79% 88.79%
=======================================
Files 296 296
Lines 41319 41328 +9
=======================================
+ Hits 36688 36698 +10
+ Misses 4631 4630 -1 ☔ View full report in Codecov by Sentry. |
rjsparks
requested changes
Jul 20, 2024
Comment on lines
+458
to
+462
| if user_query.filter(person__isnull=True).count() == 1: # Can't inspect user.person direclty here | ||
| log.log(f"Direct auth of personless user {user.pk}:{user.username}") | ||
| else: | ||
| log.log(f"Direct auth: {user.pk}:{user.person.plain_name()}") | ||
| log.log(f"Direct auth success: {username}") |
Member
There was a problem hiding this comment.
This is overly chatty - can we tighten it up so that we don't get two log lines as we go through this code?
Contributor
Author
There was a problem hiding this comment.
Good point. I added the Direct auth success prefix to each successful response above.
rjsparks
approved these changes
Jul 21, 2024
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
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Resolves #7709