feat: project/dataset view permissions#255
Open
v-rocheleau wants to merge 4 commits into
Open
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #255 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 56 56
Lines 1731 1733 +2
Branches 177 177
=========================================
+ Hits 1731 1733 +2
🚀 New features to boost your workflow:
|
This was referenced Apr 1, 2025
davidlougheed
requested changes
Apr 3, 2025
| ) | ||
| P_QUERY_DATASET_LEVEL_COUNTS = Permission(QUERY_VERB, DATASET_LEVEL_COUNTS, gives=(P_QUERY_DATASET_LEVEL_BOOLEAN,)) | ||
|
|
||
| # Data catalog: permissions to view project/dataset metadata |
Member
There was a problem hiding this comment.
i'd move these above the query permissions so those can all be grouped together
| P_QUERY_DATASET_LEVEL_COUNTS = Permission(QUERY_VERB, DATASET_LEVEL_COUNTS, gives=(P_QUERY_DATASET_LEVEL_BOOLEAN,)) | ||
|
|
||
| # Data catalog: permissions to view project/dataset metadata | ||
| P_VIEW_DATASETS = Permission(VIEW_VERB, DATASET, min_level_required=LEVEL_INSTANCE) |
Member
There was a problem hiding this comment.
this should give view:projects imo, since a dataset without a project isn't very useful. unless there's a reason not to?
|
|
||
| # Data catalog: permissions to view project/dataset metadata | ||
| P_VIEW_DATASETS = Permission(VIEW_VERB, DATASET) | ||
| P_VIEW_PROJECTS = Permission(VIEW_VERB, PROJECT, min_level_required=LEVEL_PROJECT) |
Member
There was a problem hiding this comment.
add supports_data_type_narrowing=False to these
Member
There was a problem hiding this comment.
(although I should rethink how this logic works, should be false by default I think)
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Intended for data catalog, for situations where listing the metadata of projects/datasets must be authorized.
Accompanying Katsu/Bento PRs will:
BENTO_KATSU_PUBLIC_PROJECTS_AUTHZBENTO_KATSU_PUBLIC_DATASETS_AUTHZ/projectsand/datasetsendpoints authz protected based on the feature flags