Skip to content

Commit

Permalink
bug: Fix dataset permissions (#1601)
Browse files Browse the repository at this point in the history
  • Loading branch information
ravenac95 authored Jun 6, 2024
1 parent bfe89d8 commit 034fa06
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions warehouse/oso_dagster/utils/bq.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,13 @@ def ensure_dataset(client: BQClient, options: DatasetOptions):
access_entries = dataset.access_entries
new_entries: List[AccessEntry] = []
if options.is_public:
if len(access_entries) == 0:
new_entries.append(
AccessEntry(
role="READER",
entity_type=EntityTypes.SPECIAL_GROUP,
entity_id="allAuthenticatedUsers",
)
new_entries.append(
AccessEntry(
role="READER",
entity_type=EntityTypes.SPECIAL_GROUP.value,
entity_id="allAuthenticatedUsers",
)
)
for entry in access_entries:
if entry.entity_id == "allAuthenticatedUsers":
continue
Expand Down

0 comments on commit 034fa06

Please sign in to comment.