Add the 0.10 upgrade guide, the missing sqlmodel release note, and a BackendVarFormatError hint

Merged
MA
24d ago
+221-12

All Submissions:

  • Have you followed the guidelines stated in CONTRIBUTING.md file?
  • Have you checked to ensure there aren't any other open Pull Requests for the desired changed?

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • This change requires a documentation update

Changes To Core Features:

  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your core changes, as applicable?
  • Have you successfully ran tests with your changes locally?

What

Three commits closing the documentation and error-message gaps the 0.10.0a2 pre-release QA rated "fix before release" (prerelease_testing/2026-10-07/RELEASE_PLAN.md on claude/reflex-prerelease-testing-t0sd90).

  1. Name the fix in BackendVarFormatError (fixes #7475). Field.__format__'s backend-var branch still names 'Owner.var' and now adds that the code can use Owner.var.default_value(), declare the var as ClassVar[...] for a constant shared by all sessions, or use a regular state var for a value the UI should show and update. Unit test test_backend_field_format_error_names_the_fix (parametrized; failed before). Fragment in packages/reflex-base/news/.
  2. Add the missing release note for lifting the sqlmodel cap (fixes #7474, item 1). #7462 added no fragment of its own and only trimmed #7424's; the a1 changelog had the cap sentence, the a2 changelog dropped it. news/7462.misc.md states that the sqlmodel<0.0.45 cap is gone, that from 0.0.45 a plain datetime is stored as UTC, what uv pip install -U from 0.10.0a1 does (verified by dry-run: sqlmodel 0.0.44 → 0.0.48, SQLAlchemy 2.0.54 → 2.1.3), and how to keep naive datetimes (sa_type=DateTime(timezone=False) or a pin); docs/database/tables.md gains the matching paragraph.
  3. Add an Upgrading to Reflex 0.10 guide (fixes #7474, items 2 and 3): new docs/changelog/upgrading/upgrading-to-0-10.md, the first item of the Changelog section of the API reference sidebar inside an "Upgrading" accordion that later upgrade guides can join (with a sidebar test; only the package changelogs pulled in from outside the docs tree get the changelog rendering, so other pages under docs/changelog/ are ordinary docs). It covers the class-level read returning Field with a replacement table, that default_value() does not exist on 0.9.x and the portable State.get_fields()["_x"].default_value() form, the scope of #7461 class-default assignment (new instances only, annotation-checked, a zero-arg callable called once, mutable defaults copied, shared live objects must be ClassVar[...] not Any/Optional[...] because non-ClassVar defaults are deep-copied and unpicklable objects then fail on first read), the background-task handler-call guard with a before/after snippet (narrowed to inherited handlers after checking 0.9.12: a handler declared on the substate already raised; news/7312.breaking.md added), and one line each with PR links for #7370, #7312 and #7462. docs/vars/base_vars.md and docs/events/background_events.md cross-link into it.

Every code sample in the guide was executed on this tree and, where noted, on a fresh 0.9.12; all /docs links and anchors were validated against the registered routes.

Test plan

  • uv run ruff check . / ruff format --check . clean; uv run pyright reflex tests 0 errors; pre-commit on the changed files (ruff, codespell, pyi, pyright, ty) passes.
  • BASE_REF=origin/main uv run reflex-release changelog-check: fragments present; towncrier drafts render the new fragments with PR links.
  • Unit tests for reflex_base/vars, components, events and vars: 616 passed; the full suite's only failures are the 232 reflex_cli/v2 version-check tests and the Playwright-less bench driver test, both environmental and identical on main.
  • Docs app tests (from docs/app, browser-driven files excluded): 664 passed, 1 skipped, 6 xfailed (link/SEO checks that need an exported site). The docs site itself was not built here (the full docs app import needs a reflex-enterprise login).

Judgement calls for review: the guide is a new public URL (/docs/changelog/upgrading/upgrading-to-0-10/); 7462.misc.md and 7312.breaking.md use PR-number names; the sqlmodel entry is typed misc because 0.9.12 already allowed sqlmodel up to 0.1 and the exposure is a1 → a2 upgraders. The BackendVarFormatError change covers the f-string / format() path only; str(), % and !r still embed Field(...) silently.

šŸ¤– Generated with Claude Code

https://claude.ai/code/session_01SjCrbdguMkfe4bhbaREiwo


Generated by Claude Code


Generated by Claude Code