Repository navigation
build: bump FOCA to 0.22.0 - #463
Conversation
Work in progress; local checks not finished yet. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Pin foca-plugins and its routing plugins to the merge commit of foca-plugins#62 (7a08e7f), which allows FOCA 0.22, in pyproject.toml, uv.lock and the Dockerfile. The upgrade notes of 0.6.0 name FOCA 0.22 and what changes in responses, plugin gateway messages and logs. Refs #462 Co-Authored-By: Claude Opus 5.5 <[email protected]>
Refs #462 Co-Authored-By: Claude Opus 5.5 <[email protected]>
Reviewer's GuideConfigurationUpgrade the application and container to FOCA 0.22, pin compatible routing plugins, and keep the smoke-test plugin dependency aligned.
Retain validation reasons in error details under FOCA 0.22 while enabling the updated validation response behavior.
DocumentationUpdate migration guidance and FOCA version references to explain the 0.22 behavior and compatibility requirements.
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Refs #462 Co-Authored-By: Claude Opus 5.5 <[email protected]>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## dev #463 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 31 31
Lines 3013 3013
=========================================
Hits 3013 3013 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Hey - I've found 2 issues
Prompt for AI Agents
Please address the comments from this code review:
## Individual Comments
### Comment 1
<location path="pro_tes/config.yaml" line_range="245" />
<code_context>
+ # 0.21; the reason quotes the rejected values (FOCA 0.22's default names
+ # the invalid fields by location and code instead)
validation_details: True
+ validation_reasons: True
# Custom configuration
</code_context>
<issue_to_address>
**Generated clients miss validation details**
When a caller generates a client from the served OpenAPI document and handles validation errors, the served OpenAPI document omits a 400 response for task creation, and its `ProblemDetails` schema lists only `title`, `status`, and `detail`, so generated clients cannot discover or type the `type`, `code`, and `errors` validation fields.
Document the task-creation 400 response and add `type`, `code`, and `errors` to the served `ProblemDetails` schema.
Also at `docs/upgrading.md:49-50`.
</issue_to_address>
### Comment 2
<location path="docs/upgrading.md" line_range="15" />
<code_context>
-notes](https://github.com/elixir-cloud-aai/foca/releases/tag/v0.21.0)). What this
-changes:
+**FOCA 0.22 (all deployments):** proTES now requires FOCA 0.22.0, on the FOCA
+0.22.0 image (see FOCA's release notes of
+[0.21.0](https://github.com/elixir-cloud-aai/foca/releases/tag/v0.21.0) and
+[0.22.0](https://github.com/elixir-cloud-aai/foca/releases/tag/v0.22.0), and
</code_context>
<issue_to_address>
**Add release notes**
The issue asks for both upgrade notes and release notes. The change updates the upgrade notes but does not add or update release notes for this upgrade.
</issue_to_address>Linked issues
#462 build: bump FOCA to 0.22.0 · 2 of 3 met
| # | Requirement | Status | Notes |
|---|---|---|---|
| 1 | Bump FOCA to 0.22.0 in the dependency, lockfile, and pinned base image. | ✅ Met | The dependency constraint and base image are updated; the PR description also reports the lockfile update. |
| 2 | Follow the migration guide, adjust affected tests, and fix compatible deprecations or list the rest as follow-ups. | ✅ Met | The config preserves validation reasons, the migration effects are documented, and the PR description lists the deferred deprecations. |
| 3 | Update docs naming the FOCA version, including upgrade notes and release notes. | 🟡 Partly met | The upgrade notes and other version references are updated, but no release notes for this upgrade are added or changed. |
Sourcery assessment
Approval pending. 1 finding to address first.
Blocking findings: pro_tes/config.yaml:245
Closes #462
Summary
Same approach as cloud-registry#382.
foca>=0.22.0,<0.23inpyproject.toml,uv.lock, and the base imageelixircloud/foca:0.22.0-py3.13, pinned by digest, in theDockerfile. That base image no longer has the zlib1g findings that fail the image scan with the 0.21.0 base. There were no Trivy ignores for them to remove.7a08e7f, the merge of build: support FOCA 0.22 foca-plugins#62, which allows FOCA 0.22. The pin is the same inpyproject.toml,uv.lockand theADDof theDockerfile. The releases of foca-plugins still capfoca<0.21, so the commit pin stays until one allows FOCA 0.22.exceptions.validation_reasons: Trueinpro_tes/config.yamlkeeps the validator's reason asdetail, as up to FOCA 0.21 and astest_validation_detailsexpects. Responses gain FOCA 0.22'stype,code(invalid-request) anderrors. In cloud-registry the same setting goes away once the app names invalid fields itself (cloud-registry#378); proTES can follow later.docs/upgrading.md(To version 0.6.0): FOCA 0.22, validation errors, plugin gateway messages, logs, and the plugin cap.docs/api.md(provenance example),docs/plugins.md,docs/plugin-images.mdanddeployment/README.md.tests/smoke/plugin) now requiresfoca>=0.22.0,<0.23.Deprecations left for follow-ups
pro_tes/exceptions.py) uses werkzeug classes, and FOCA logs a warning per class at startup. The switch tofoca.errorsisn't compatible yet: raw werkzeug exceptions such as Flask's 404 would stop matching.flask-import).Foca.create_celery_app()is already the supported API.How it was verified
coverage run -m pytest -W ignore::DeprecationWarning: 1807 passed, 11 skipped, 100% coverage (Helm 3.22.1, withhelm dependency build deploymentand thecharts.sha256check passing).mkdocs build --strict, pre-commit (CI runs it), and the integration tests with services. CI runs them.Review
Full lane (it changes config and pins), one round of the adversarial reviewer. It had low findings only; two doc findings are fixed (log levels, plugin gateway messages).
Declined review findings
pyproject.tomlcomment mixesfoca<0.21and FOCA 0.22": both are right. The releases of foca-plugins capfoca<0.21, and the commit pin can go once a release allows FOCA 0.22, whichdocs/development.mddescribes too.Open questions
None.
🤖 Generated with Claude Code
Summary by Sourcery
Upgrade proTES and its container dependencies to FOCA 0.22 while maintaining compatible plugin, validation, and deployment behavior.
Enhancements:
Build:
Documentation: