Skip to content

Add REPARSE_ALL permission for reparsing files with no registered Dag - #73274

Merged
pierrejeambrun merged 2 commits into
apache:mainfrom
astronomer:add-reparse-all-permission
Sep 17, 2026
Merged

pierrejeambrun merged 2 commits into
apache:mainfrom
astronomer:add-reparse-all-permission

Conversation

@pierrejeambrun

Copy link
Copy Markdown
Member

Reparsing a file that failed to import before defining any Dag has no per-Dag key to authorize against. Viewing such a file's import error is already gated on the dedicated IMPORT_ERRORS_ALL view; reparsing it is a distinct action, and gating a write on a view permission would let anyone who can see the error also trigger the reparse.

This adds a dedicated AccessView.REPARSE_ALL -- admin-granted by default, and scoped per team via the file's bundle where the auth manager supports multi-team isolation -- mirroring IMPORT_ERRORS_ALL (#69790).

  • New AccessView.REPARSE_ALL.
  • The Simple auth manager gates it admin-only; the FAB manager grants it to Admin by default (All Reparses resource). Keycloak and Amazon authorize views generically, so they need no change.
  • Not yet consumed by any endpoint: it is the prerequisite for Add reparse button to the Dag import errors modal #72896, which gates reparse of files with no registered Dag on it.

related: #69790


Was generative AI tooling used to co-author this PR?
  • Yes — Claude Code (Opus 4.8)

Generated-by: Claude Code (Opus 4.8) following the guidelines

Reparsing a file that has no registered Dag needs a permission of its own: such a file has no per-Dag key to authorize the reparse against, and the existing IMPORT_ERRORS_ALL view only governs seeing those errors. Gating the reparse action on that view would let anyone who can view an error also trigger its reparse. A dedicated admin-by-default, team-scoped permission keeps seeing and acting separate. It is consumed by a follow-up that adds reparse of unregistered files from the UI.
This PR extends the common-compat access-view shim with REPARSE_ALL, which the
FAB auth manager consumes, so FAB needs the upcoming common-compat release. The
"# use next version" marker records that intent and satisfies the provider
dependency CI guard that fires when common-compat changes alongside a provider.
@pierrejeambrun pierrejeambrun added this to the Airflow 3.4.0 milestone Sep 17, 2026
@pierrejeambrun
pierrejeambrun merged commit 68c8dc8 into apache:main Sep 17, 2026
125 checks passed
@pierrejeambrun
pierrejeambrun deleted the add-reparse-all-permission branch September 17, 2026 14:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants