Repository navigation
docs: complete the 0.18 migration guide - #531
Merged
Merged
Conversation
Add the missing sections: the validated top-level plugins section, gateway plugins (Foca(gateway=...), refused middleware keys, one gateway app per process, client pipelines off by default), opt-in roles, GuardedClient and the new direct dependencies, and the allowlisted image build contexts. Note that an issuer's claim_groups satisfies the group claim check. Link the 0.18 guide from the README and the docs index, and list gateway plugins and the guarded HTTP client among the features. Closes #523 Co-Authored-By: Claude Opus 5.5 <[email protected]>
Reviewer's GuideThis documentation-only PR completes the 0.18 migration guide against the final implementation, covering plugin and gateway breaking changes plus opt-in roles, guarded HTTP requests, dependencies, and Docker build contexts. It also updates README/docs navigation and feature summaries so the new guide and capabilities are discoverable. Sequence diagram for gateway plugin request processingsequenceDiagram
participant Client
participant GatewayApp
participant PluginEngine
participant Backend
Client->>GatewayApp: HTTP request
GatewayApp->>PluginEngine: process request with plugins.pipeline
PluginEngine->>Backend: route validated and sanitized request
Backend-->>PluginEngine: response
PluginEngine-->>GatewayApp: plugin-processed response
GatewayApp-->>Client: HTTP response
Sequence diagram for guarded requests to untrusted URLssequenceDiagram
participant Plugin as GatewayPlugin
participant GuardedClient
participant Target
Plugin->>GuardedClient: request
GuardedClient->>GuardedClient: validate public address
GuardedClient->>Target: connect
GuardedClient->>GuardedClient: check address after connecting
alt valid response
Target-->>GuardedClient: response within limits
GuardedClient-->>Plugin: response
else redirect or invalid response
Target-->>GuardedClient: redirect or rejected response
GuardedClient-->>Plugin: guarded result
end
Flow diagram for gateway configuration validation and startupflowchart TD
Config["Configuration"] --> PluginsConfig["PluginsConfig validation"]
PluginsConfig -->|"invalid keys"| ValidationError["ValidationError"]
PluginsConfig --> GatewayCheck["Gateway app checks"]
GatewayCheck -->|"middlewares or custom.middlewares"| StartupError["Startup ValueError"]
GatewayCheck -->|"valid gateway configuration"| LoadPlugins["Load and check plugins"]
LoadPlugins --> RunningGateway["Running gateway app"]
PluginsConfig -->|"non-gateway app"| Warning["Warning; no plugins loaded"]
File-Level Changes
Assessment against linked issues
Possibly linked issues
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## dev #531 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 55 55
Lines 6667 6667
=========================================
Hits 6667 6667
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
uniqueg
marked this pull request as ready for review
October 26, 2026 22:03
There was a problem hiding this comment.
Hey - I've found 1 issue
Prompt for AI Agents
Please address the comments from this code review:
## Individual Comments
### Comment 1
<location path="docs/migration-0.18.md" line_range="183" />
<code_context>
+ a request (tag `gateway.pipeline`) only if
+ `plugins.client_pipelines.enabled` is `true` (default: `false`), and
+ only when authenticated; backend
+ choices (`plugins.client_backends`) are on by default, as they only
+ narrow or reorder the candidates. A client pipeline or preset replaces
+ `plugins.pipeline`, framed by `client_pipelines.prepend` and `append`,
</code_context>
<issue_to_address>
**Anonymous backend choices fail**
When a caller uses `gateway.backends` without authenticating, `PluginHost.start()` rejects any supplied backend choice from an unauthenticated caller with `InvalidSelection` (`400`), so callers who read “on by default” as meaning they can use backend choices without authentication get rejected requests.
State explicitly that backend choices, like pipeline choices, require an authenticated caller, even though they are enabled by default.
</issue_to_address>Sourcery assessment
Approved.
Address review: both client tags are refused from unauthenticated callers. Part of #523 Co-Authored-By: Claude Opus 5.5 <[email protected]>
Part of #523 Co-Authored-By: Claude Opus 5.5 <[email protected]>
This was referenced Oct 26, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Completes the 0.18 migration guide and the docs entry points, written after #515, #517, #518 and #519 were fixed (PRs #521, #525, #526, #527), so that they match the final behaviour.
docs/migration-0.18.md:pluginsvalidated (PluginsConfig,extra="forbid", also for apps that are no gateways); Gateway plugins (Foca(gateway=...), refusal ofmiddlewares/custom.middlewares, one gateway app per process incl. the Celery worker note, client pipelines off by default, authenticated callers only, and where policy steps belong).opt_in_roles,opt_in_header, startup errors,400from the permissions API, warning on stored rules,Vary, CORS); Guarded HTTP client and dependencies (GuardedClient,urllib3>=2.6,<3,packaging>=23); Image build contexts (allowlist.dockerignorefiles, fix: keep local files out of example images #513 and fix: close small pre-release review gaps #516).claim_groupsalso satisfies the check (feat(auth): add per-issuer settings #514); same note indocs/configuration/access-control.md.Also:
README.mdanddocs/index.mdlink the 0.18 guide (0.17 in the chain); the README feature list (also the docs index synopsis) mentions gateway plugins and the guarded HTTP client;docs/plugins.mdsays thepluginssection must be valid in apps that are no gateways, too.Closes #523
Light lane: docs only (no code, config or CI changes); I reviewed the diff myself against the code (
foca/models/config.py,foca/plugins/,foca/config/config_parser.py,register_access_control.py).Verification
mkdocs build --strict(with anchor validation): passes.pytest -m "not mongodb": 2822 passed, 1 skipped.🤖 Generated with Claude Code
Summary by Sourcery
Complete the 0.18 migration documentation and update documentation entry points to reflect the finalized release behavior.
Enhancements:
Documentation: