[Feature] Preview and explain policy impact before governed changes #10

Closed
opened 2026-07-31 01:22:04 +02:00 by zemion · 2 comments
Owner

Moved from Core #137. Policy owns effective-policy evaluation and provenance; Core supplies only generic capability and UI contracts.

Outcome

Let an authorized actor understand which resources, scopes, users, and actions a proposed policy change would affect before committing it.

Acceptance criteria

  • A bounded dry-run capability compares current and proposed effective policy without persisting the proposal.
  • Results group newly allowed, newly denied, unchanged, and indeterminate effects and retain rule/source/scope provenance.
  • Callers choose an explicit resource population or provider; the API never performs an unbounded platform scan.
  • Sensitive counts/details remain permission-filtered and explain when results are sampled, truncated, unavailable, or hidden.
  • The shared admin surface requires recent authorization for high-impact changes and records preview and commit audit events.
  • Optional module providers can contribute impact subjects without Policy importing module implementations.
> Moved from [Core #137](https://git.add-ideas.de/GovOPlaN/govoplan-core/issues/137). Policy owns effective-policy evaluation and provenance; Core supplies only generic capability and UI contracts. ## Outcome Let an authorized actor understand which resources, scopes, users, and actions a proposed policy change would affect before committing it. ## Acceptance criteria - A bounded dry-run capability compares current and proposed effective policy without persisting the proposal. - Results group newly allowed, newly denied, unchanged, and indeterminate effects and retain rule/source/scope provenance. - Callers choose an explicit resource population or provider; the API never performs an unbounded platform scan. - Sensitive counts/details remain permission-filtered and explain when results are sampled, truncated, unavailable, or hidden. - The shared admin surface requires recent authorization for high-impact changes and records preview and commit audit events. - Optional module providers can contribute impact subjects without Policy importing module implementations.
Author
Owner

Moved here from Core #137; the source issue is closed to keep Policy as the canonical owner.

<!-- codex-routing-2026-07-31:core-137 --> Moved here from [Core #137](https://git.add-ideas.de/GovOPlaN/govoplan-core/issues/137); the source issue is closed to keep Policy as the canonical owner.
Author
Owner

Implemented and published the governed policy impact-preview slice.

Evidence:

  • Core 4f4007a: bounded optional PolicyImpactSubjectProvider contract with explicit provider/population selection, hard limits, and coverage states.
  • Views 24dca43: tenant-safe bounded View/surface subject projection with permission-filtered labels and no implicit unbounded scan.
  • Policy 861e9b8: dry-run current/proposed evaluation with allowed/denied/unchanged/indeterminate counts, rule/source/scope provenance, hidden-detail explanations, stale-preview binding, recent authentication for system-scope changes, preview/commit audit linkage, and shared admin UI workflow.
  • Reset-to-inherited changes require their own fresh preview; proposal hashes bind both the draft and current base revision.
  • Provider failures remain isolated and operator-visible without leaking raw exception details.

Verification passed:

  • Policy: 61 tests; Ruff; interface-pattern contract.
  • Views: 39 tests + 5 subtests; Ruff.
  • Core targeted contract/API smoke: 9 tests; Ruff.
  • Manifest registry: 68/68; strict interface inventory.
  • Integrated Core WebUI build and bundle budget.
  • Full tools/checks/check-focused.sh: backend/integration suites, 59 module permutations, full-product build, and 7 Playwright conformance tests.
Implemented and published the governed policy impact-preview slice. Evidence: - Core `4f4007a`: bounded optional `PolicyImpactSubjectProvider` contract with explicit provider/population selection, hard limits, and coverage states. - Views `24dca43`: tenant-safe bounded View/surface subject projection with permission-filtered labels and no implicit unbounded scan. - Policy `861e9b8`: dry-run current/proposed evaluation with allowed/denied/unchanged/indeterminate counts, rule/source/scope provenance, hidden-detail explanations, stale-preview binding, recent authentication for system-scope changes, preview/commit audit linkage, and shared admin UI workflow. - Reset-to-inherited changes require their own fresh preview; proposal hashes bind both the draft and current base revision. - Provider failures remain isolated and operator-visible without leaking raw exception details. Verification passed: - Policy: 61 tests; Ruff; interface-pattern contract. - Views: 39 tests + 5 subtests; Ruff. - Core targeted contract/API smoke: 9 tests; Ruff. - Manifest registry: 68/68; strict interface inventory. - Integrated Core WebUI build and bundle budget. - Full `tools/checks/check-focused.sh`: backend/integration suites, 59 module permutations, full-product build, and 7 Playwright conformance tests.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: GovOPlaN/govoplan-policy#10