-
Notifications
You must be signed in to change notification settings - Fork 28
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
ref: Handle current_user in base #203
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅ 📢 Thoughts on this report? Let us know!. |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #203 +/- ##
=======================================
Coverage 95.61% 95.61%
=======================================
Files 600 600
Lines 15223 15224 +1
=======================================
+ Hits 14556 14557 +1
Misses 667 667
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Codecov Report
@@ Coverage Diff @@
## main #203 +/- ##
=======================================
Coverage 95.61% 95.61%
=======================================
Files 600 600
Lines 15223 15224 +1
=======================================
+ Hits 14556 14557 +1
Misses 667 667
Flags with carried forward coverage won't be shown. Click here to find out more.
|
Codecov Report
@@ Coverage Diff @@
## main #203 +/- ##
=====================================
Coverage 95.52 95.52
=====================================
Files 714 714
Lines 15629 15630 +1
=====================================
+ Hits 14929 14930 +1
Misses 700 700
Flags with carried forward coverage won't be shown. Click here to find out more.
|
codecov/commands/base.py
Outdated
if self.current_owner: | ||
self.current_user = self.current_owner.user | ||
if self.current_owner and not self.current_user.is_authenticated: | ||
self.current_user = self.current_owner |
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.
This is mixing types. I think this could remain as:
if self.current_owner:
self.current_user = self.current_owner.user
self.current_user
is eitherUser
orAnonymousUser
self.current_owner
is eitherNone
orOwner
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.
oh sorry lost with the new changes
Purpose/Motivation
What is the feature? Why is this being done?
passing current_user to use instead of relying on owner
Links to relevant tickets
TBD
What does this PR do?
Include a brief description of the changes in this PR. Bullet points are your friend.
Notes to Reviewer
Anything to note to the team? Any tips on how to review, or where to start?
..
Legal Boilerplate
Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. In 2022 this entity acquired Codecov and as result Sentry is going to need some rights from me in order to utilize my contributions in this PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.