Skip to content

docs: point upgraders to the 0.20.0 guide - #651

Merged
uniqueg merged 3 commits into
devfrom
docs/upgrade-to-0-20
Nov 3, 2026
Merged

uniqueg merged 3 commits into
devfrom
docs/upgrade-to-0-20

Conversation

@uniqueg

@uniqueg uniqueg commented Nov 3, 2026 •

Copy link
Copy Markdown
Member

Summary

The README and the docs index still sent people who upgrade to the guide for 0.18.0. This points both at the guide for 0.20.0 and adds a test that keeps them on the newest guide.

Smaller docs findings of the pre-release review:

  • Migration guide: the reasons for errors in the TLS handshake now match what GuardedClient does (reset: connect_error; closed: tls_error; deadline: DeadlineExceeded).
  • Migration guide: pip in a running container breaks too, and the plugins of foca-plugins need a release that allows FOCA 0.20.
  • Getting started and migration guide: python -m venv installs an old pip on Python 3.11 and 3.12.
  • Deployment: the plugin store's warnings under "Startup checks".

Closes #648

How it was verified

  • pytest tests/test_repository.py tests/test_version_mentions.py: 86 passed.
  • ruff check, ruff format --check, mkdocs build --strict: passed.

Light lane: only docs and one test of the docs, so no reviewer subagents; I reviewed the diff myself.

🤖 Generated with Claude Code

https://claude.ai/code/session_011FSoqMUX3EU35poH13xMgG

Summary by Sourcery

Keep upgrade documentation aligned with the latest release and add guidance from the 0.20.0 pre-release review.

Bug Fixes:

  • Update upgrade references in the README and documentation index to the 0.20.0 migration guide.

Enhancements:

  • Clarify 0.20.0 migration guidance for pip usage, plugin compatibility, and TLS handshake errors.
  • Document plugin-store warnings shown during deployment startup checks.

Documentation:

  • Refresh getting-started and migration guidance for vulnerable bundled pip versions on Python 3.11 and 3.12, and document alternatives.
  • Correct migration documentation for TLS handshake outcomes, running-container package installation, and foca-plugins release compatibility.

Tests:

  • Add a repository test ensuring the README and documentation index link to the newest migration guide.

The README and the docs index still named the guide for 0.18.0, which
doesn't cover 0.20.0's main breaking change. PyPI descriptions and the
docs of tags can't change after a release. A test keeps both on the
newest guide.

Also correct the reasons for errors in the TLS handshake, say that pip
in a running container breaks and that foca-plugins needs a release for
FOCA 0.20, warn about the old pip of virtual environments on Python 3.11
and 3.12, and list the plugin store's warnings under startup checks.

Closes #648

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_011FSoqMUX3EU35poH13xMgG
@sourcery-ai

sourcery-ai Bot commented Nov 3, 2026 •

Copy link
Copy Markdown

Reviewer's Guide

Updates README and documentation navigation to target the 0.20.0 migration guide, refreshes migration and deployment guidance for current packaging, TLS, plugin, and startup-warning behavior, and adds a test to prevent upgrade links from becoming stale.

Flow diagram for current migration guide links

flowchart LR
    README[README upgrade link] --> Guide[0.20.0 migration guide]
    Index[Documentation index] --> Guide
    Test[Repository link test] --> README
    Test --> Index
Loading

Flow diagram for updated Python package installation guidance

flowchart TD
    Venv[Create virtual environment with python -m venv] --> Version{Python 3.11 or 3.12}
    Version -->|Yes| Upgrade[Upgrade pip or use uv pip install --python]
    Version -->|No| Install[Install packages]
    Upgrade --> Install
    Runtime[Running-container pip install] --> Alternative[Use uv in the image or another package installation method]
Loading

File-Level Changes

Change Details Files
Point upgrade entry points to the 0.20.0 migration guide and preserve links to prior migration versions.
  • Updated the README’s primary migration link and version sequence.
  • Added the 0.18.0 README reference link and updated the documentation index ordering.
README.md
docs/index.md
Refresh migration and operational documentation for 0.20.0 packaging, TLS behavior, and deployment considerations.
  • Documented old vulnerable pip versions from Python 3.11/3.12 virtual environments and recommended uv or pip upgrade paths.
  • Covered pip execution in running containers and foca-plugins release compatibility.
  • Aligned TLS handshake error guidance with GuardedClient reset, close, and deadline outcomes.
  • Added plugin store startup warnings to deployment documentation.
docs/migration-0.20.md
docs/getting-started.md
docs/deployment.md
Add a repository-level regression test that verifies upgrade links stay on the newest migration guide.
  • Derives the newest migration version from the documentation filenames.
  • Checks both the README reference URL and docs index entry against that version.
tests/test_repository.py

Possibly linked issues


Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@codecov

codecov Bot commented Nov 3, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (ac58395) to head (69978f8).

Additional details and impacted files
@@            Coverage Diff            @@
##               dev      #651   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           56        56           
  Lines         7142      7142           
=========================================
  Hits          7142      7142           
Flag Coverage Δ
test_unit 100.00% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@uniqueg
uniqueg marked this pull request as ready for review November 3, 2026 10:18
sourcery-ai[bot]
sourcery-ai Bot previously approved these changes Nov 3, 2026

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sourcery assessment

Approved.

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey - I've found 3 issues

Prompt for AI Agents
Please address the comments from this code review:

## Individual Comments

### Comment 1
<location path="docs/deployment.md" line_range="175" />
<code_context>
+- [plugin store](configuration/plugins.md#plugin-store) of gateway apps:
+  plugins that keep stored data in the memory of each process, as no database
+  is configured, or in the database without a secret for their keys, and
+  indexes that could not be created;
 - [authentication](configuration/auth.md), on the first token validation
   rather than on startup: no trusted `issuers`, disabled audience or token
</code_context>
<issue_to_address>
**Persistent index errors look like warnings**

When mongoDB returns a permanent error while creating plugin-store indexes, the deployment checklist groups these failures with startup warnings even though they are logged at ERROR level, so operators get inaccurate guidance about their severity.

Separate persistent index-creation failures from startup warnings and identify their ERROR severity.

Also at `docs/deployment.md:176`.
</issue_to_address>

### Comment 2
<location path="docs/getting-started.md" line_range="198" />
<code_context>
-final stage doesn't. The [petstore
+final stage doesn't. On Python 3.11 and 3.12, the bundled pip is old and has
+known vulnerabilities, so upgrade it first (`pip install --upgrade
+"pip>=26.2"`) or use `uv pip install --python <environment>`. The [petstore
 example](https://github.com/elixir-cloud-aai/foca/tree/dev/examples/petstore)
 installs Gunicorn with uv as above.
</code_context>
<issue_to_address>
**The uv fallback command fails**

When a reader follows the uv alternative as written, the documented `uv pip install --python <environment>` invocation has no package or requirements argument, so uv rejects it instead of installing the build-stage dependencies.

Show the package or requirements arguments to pass to `uv pip install`, or label this explicitly as a command prefix and include a complete example.

Also at `docs/migration-0.20.md:55`.
</issue_to_address>

### Comment 3
<location path="tests/test_repository.py" line_range="28" />
<code_context>
+    )
+    readme = (ROOT / "README.md").read_text(encoding="utf-8")
+    index = (ROOT / "docs" / "index.md").read_text(encoding="utf-8")
+    assert f"/latest/migration-{newest}/>" in readme.split("[docs-migration]:")[1]
+    assert f"(migration-{newest}.md)" in index
+
</code_context>
<issue_to_address>
**Newest migration links go untested**

When a page retains the destination text after its rendered link is removed, `test_newest_migration_guide_linked` checks the README reference definition and parenthesized index text rather than rendered links, so it passes while the newest guide is not clickable and upgraders can still be sent to an older guide.

Assert that the README upgrade text uses the migration reference and that the index contains an actual link to the newest guide.

Also at `tests/test_repository.py:29`.
</issue_to_address>

Linked issues

#648 docs: point upgraders to the 0.20.0 guide · 5 of 5 met

# Requirement Status Notes
1 Point the README at migration-0.20 and list 0.20.0 in docs/index.md. ✅ Met The README link and docs index entry both point to the 0.20.0 guide.
2 Test that the newest migration guide is linked from both. ✅ Met The new test finds the newest migration guide and checks for it in both the README and docs index.
3 Correct TLS handshake error reasons; cover pip in a running image and foca-plugins compatibility. ✅ Met The migration guide distinguishes reset, close, and deadline errors, and covers running-container pip recipes and the required foca-plugins release.
4 List the plugin store's warnings under Deployment's Startup checks. ✅ Met The deployment documentation adds plugin-store warnings to the Startup checks list.
5 Explain in Getting started and the migration guide that Python 3.11 and 3.12 virtual environments bundle old pip, and advise upgrading it or using uv. ✅ Met Both guides include the warning and the upgrade-or-uv guidance.

Sourcery assessment

Approval pending. 3 findings to address first.

Blocking findings: docs/deployment.md:175, docs/getting-started.md:198, tests/test_repository.py:28


Sourcery is free for open source - if you like our reviews please consider sharing them ✨

Comment thread docs/deployment.md Resolved
Comment thread docs/getting-started.md Resolved
Comment thread tests/test_repository.py Resolved
@sourcery-ai
sourcery-ai Bot dismissed their stale review November 3, 2026 10:24

Sourcery withdrew this approval because the latest commits introduced blocking findings.

@uniqueg
uniqueg merged commit 397fff1 into dev Nov 3, 2026
56 checks passed
@uniqueg
uniqueg deleted the docs/upgrade-to-0-20 branch November 3, 2026 10:33
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.

docs: point upgraders to the 0.20.0 guide

1 participant