Skip to content

fix(auth): exclude Admin and Cloud Identity scopes from Read Only preset - #977

Closed
pederbe wants to merge 1 commit into
googleworkspace:mainfrom
pederbe:contrib/258-readonly-scopes
Closed

pederbe wants to merge 1 commit into
googleworkspace:mainfrom
pederbe:contrib/258-readonly-scopes

Conversation

@pederbe

@pederbe pederbe commented Nov 4, 2026

Copy link
Copy Markdown

Description

The discovery picker's Read Only preset selects admin.* and cloud-identity.* scopes, including cloud-identity.devices.readonly reported in #258. Exclude these two families from template selection and final scope resolution. Admin scopes remain available through individual selection, Full Access, and explicit --scopes.

Regression tests cover the reported families, preservation of other read-only scopes including Classroom, and explicit admin scope resolution. Validation uses synthetic discovery entries rather than live OAuth consent.

Workspace tests and the build pass for this change alone. Strict Clippy on Rust 1.99.1 encounters two existing errors in unchanged files: double_must_use in auth.rs and collapsible_match in helpers/script.rs. PR #976 addresses those errors, and strict Clippy passes with that repair applied. This PR targets main independently so the OAuth fix can be reviewed in parallel.

The dependency-policy check also reports the same twelve existing advisory IDs on the clean base and the separate baseline repair.

Related to #258.

Dry Run Output: Not applicable to this scope-picker fix.

Checklist:

  • My code follows the AGENTS.md guidelines (no generated google-* crates).
  • I have run cargo fmt --all to format the code perfectly.
  • I have run cargo clippy -- -D warnings and resolved all warnings. The existing failures are described above and addressed separately in fix: resolve Clippy warnings in token futures and Apps Script file selection #976.
  • I have added tests that prove my fix is effective or that my feature works.
  • I have provided a Changeset file (e.g. via pnpx changeset) to document my changes.

@changeset-bot

changeset-bot Bot commented Nov 4, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 7bc81d6

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@googleworkspace/cli Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@pederbe
pederbe marked this pull request as ready for review November 4, 2026 10:33
@github-actions

github-actions Bot commented Nov 8, 2026

Copy link
Copy Markdown
Contributor

This PR has been inactive for 72 hours. Closing to keep the queue clean.

@github-actions github-actions Bot added the Stale label Nov 8, 2026
@github-actions

github-actions Bot commented Nov 8, 2026

Copy link
Copy Markdown
Contributor

This PR was closed because it has been stalled for 72 hours. Feel free to magically reopen it if you want to continue working on it!

@github-actions github-actions Bot closed this Nov 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant