-
Notifications
You must be signed in to change notification settings - Fork 21
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
Deduped recieved scopes #6581
Deduped recieved scopes #6581
Conversation
Passing run #22487 ↗︎
Details:
Review all test suite changes for PR #6581 ↗︎ |
@@ -210,7 +210,9 @@ async def query_to_scopes(query_dict): | |||
except Exception: | |||
raise BadQueryError | |||
agg_unit = await get_agg_unit(query_dict) | |||
return [f"{agg_unit}:{tl_query_name}:{query_name}" for query_name in query_list] | |||
return list( |
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.
Do we need this to be a list, or could we return a set instead? (I don't think it matters much either way, but if we return a set it's perhaps clearer that the scopes will be non-duplicated)
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's compared to other lists when we check it against the requested scopes; now I say that, a set would be better there too, but that probably belongs in a different PR
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.
👍
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #6581 +/- ##
===========================================
- Coverage 92.31% 77.11% -15.20%
===========================================
Files 268 268
Lines 10586 10586
Branches 855 855
===========================================
- Hits 9772 8163 -1609
- Misses 676 2169 +1493
- Partials 138 254 +116 ☔ View full report in Codecov by Sentry. |
Closes #6580
I have:
Description
Passes the output of
flowapi.permissions.query_to_scopes
through aset()
before returning