Skip to content

feat(openapi): persist Swagger authorization only in development profile - #804

Draft
seonghobae wants to merge 5 commits into
developfrom
palette-swagger-persist-auth-1533328131273913812
Draft

feat(openapi): persist Swagger authorization only in development profile#804
seonghobae wants to merge 5 commits into
developfrom
palette-swagger-persist-auth-1533328131273913812

Conversation

@seonghobae

@seonghobae seonghobae commented Sep 4, 2026

Copy link
Copy Markdown
Collaborator

Current exact boundary

  • base: develop@e06b1f3fb10903569124af011da213951e6e2473
  • exact head: 0a67037ce7e21e7dbd020b20eda2e74470b98540
  • state: Draft / mechanically mergeable
  • effective files: src/newsdom_api/main.py, tests/test_health.py, CHANGELOG.md
  • generated .Jules/palette.md rule was restored to the protected-base blob; this product-local choice is not repository-wide UX doctrine.

Product contract

FastAPI's Swagger UI configuration now sets persistAuthorization: true only when RuntimeProfile.DEVELOPMENT is selected. Production retains Swagger UI's default behavior and does not opt into persisted authorization state.

Swagger UI documents persistAuthorization as false by default and states that enabling it preserves authorization data across browser close/refresh. That is the exact behavior this bounded DX change intentionally uses; it is not an accessibility-conformance claim or a general credential-storage recommendation.

The focused test now exercises the positive path with a development-profile bearer token rather than disabling authentication, while the production-profile test verifies persistAuthorization remains absent. The CHANGELOG records the same development-only boundary.

Security / UX boundary

Persisting a development token extends its lifetime inside that browser context. The change therefore stays limited to the explicit development runtime profile and makes no claim that shared/untrusted browser profiles are appropriate for secrets. Production remains fail-closed at the existing authentication boundary and does not inherit this UI convenience setting.

Promotion boundary

Keep Draft until this exact head has terminal applicable CI, security/SAST/dependency evidence, current review/thread resolution and qualifying independent review under live protection. Queued, pending, stale, predecessor, model-only, author-only or absent evidence is non-passing. No self-approval, admin bypass, gate weakening, force push, destructive rebase or no-op retrigger.

@google-labs-jules

Copy link
Copy Markdown

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

@coderabbitai

coderabbitai Bot commented Sep 4, 2026

Copy link
Copy Markdown

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@seonghobae
seonghobae marked this pull request as draft September 4, 2026 21:20
@seonghobae seonghobae changed the title 🎨 Palette: 개발 환경 Swagger UI 인증 정보 유지 추가 feat(openapi): persist Swagger authorization only in development profile Sep 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant