Skip to content

Test against the upcoming spectra and spectral, store nil as jsonb null - #2

Merged
andreashasse merged 6 commits into
mainfrom
andreashasse/spectra-0.17
Oct 31, 2026
Merged

andreashasse merged 6 commits into
mainfrom
andreashasse/spectra-0.17

Conversation

@andreashasse

Copy link
Copy Markdown
Owner

Draft: waiting for user feedback before merge and release. This is one of four aligned PRs. The Elixir ones depend on the others through git branches, so the whole set can be tried together. Nothing is released yet; the git dependencies go back to Hex versions after feedback. Depends on andreashasse/spectra#204 and andreashasse/spectral#47.

  • The bug this checks: ecto_spectral dumps values with [:pre_encoded], so with nil_fields: :null on spectral 0.16 it would have stored the string "null". A new Postgres test checks that a nil field is stored as jsonb null (jsonb_typeof = 'null') and loads back as nil.
  • Dependencies: mix.exs temporarily points :spectral and :spectra at their PR branches. Until they go back to Hex, the hex.build step in make ci fails, because Hex packages cannot depend on git. Every other step passes.
  • Lock file: decimal is updated to 3.2.0.
  • CHANGELOG: the existing entries are now under [0.1.0], which matches the tag.

Locally: 93 tests pass, and so do credo, dialyzer, the format check and mix docs.

🤖 Generated with Claude Code

andreashasse and others added 6 commits October 31, 2026 01:19
Point spectral and spectra at their pre-0.17 git branches so everything
can be tested together before release. Add a Postgres regression test
that a nil field is stored as JSON null with nil_fields set to null.
Update decimal to 3.2.0, and file the existing changelog entries under
0.1.0.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@andreashasse
andreashasse marked this pull request as ready for review October 31, 2026 08:13
@andreashasse
andreashasse merged commit 11d2fd3 into main Oct 31, 2026
2 checks passed
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