Skip to content

Releases: scripthungry/squirrelix

v0.5.15

Choose a tag to compare

@mward-sudo mward-sudo released this 10 Aug 23:29
fe7554b

Fixed

  • Ecto runner no longer emits colliding heads when a parameter is inferred as repo (e.g. def find(repo, repo)). Codegen passes a Codegen.Target reserved set into parameter name resolution.
  • Metadata/Inferrer ingress now validates params length against SQL $n placeholders and rejects return columns missing boolean nullable? with structured errors instead of crashing.

Changed

  • TypedQuery.resolve_parameter_names/2 takes an explicit reserved-name set; helper inventory lives in Codegen.Runtime.reserved_names/0.
  • Introduced Squirrelix.QueryMetadata.parse/2 as the typed boundary for metadata and inferrer keywords; Column.cast/1 / Column.to_spec/1 normalise return shapes. Explicit param name overrides via %{type: type, name: "…"}.
  • generate/3 / check/3 expand the project root and metadata map keys; metadata maps are adapted to the inferrer pipeline internally.
  • Row-type name collisions return Error.RowTypeNameCollision (via prepare/check); shared SourceRef for location context.
  • Drift comparison no longer treats // as a line comment (Elixir floor division).

Full notes: CHANGELOG.md

v0.5.14

Choose a tag to compare

@cursor cursor released this 02 Aug 02:24
5bfd51b

Added

  • Optional Ecto Repo runner: mix squirrelix.gen --runner ecto (and check) generates Repo-first functions via Ecto.Adapters.SQL.query!/3 / query/3 for connection checkout, Sandbox, and transactions — not schemas or changesets. Default remains --runner postgrex.
  • Mix --repo MODULE with --infer reads connection settings from an Ecto Repo config/0 (precedence: flags → --urlDATABASE_URL--repoPG* → defaults).

Changed

  • ROADMAP non-goals: freeze “first-class Ecto ORM integration”; allow the optional Repo runner / --repo infer path above.

Docs

  • Document optional Repo integration purpose (connection ownership / Sandbox / transactions — not schemas) in the Phoenix cookbook, Configuration (--repo, --runner), Getting Started, and README FAQ.

Hex: https://hex.pm/packages/squirr_elix
Docs: https://hexdocs.pm/squirr_elix/0.5.14

v0.5.13

Choose a tag to compare

@mward-sudo mward-sudo released this 02 Aug 01:24
a61f305

Docs

  • Trim README to end-user orientation; move roadmap / contributing / performance / release notes under docs/ (off HexDocs). HexDocs extras are README, CHANGELOG, and guides/ only (#93).
  • Point issue #24 readiness at docs/ROADMAP.md as the canonical non-goals freeze (verification, not a product-boundary laundry list).

v0.5.12

Choose a tag to compare

@mward-sudo mward-sudo released this 02 Aug 01:12
b577f03

Changed

  • Pin local and CI quality cells to Elixir 1.20.2 / OTP 28.5 via mise.toml, CI matrix, Hex publish, examples, and README; bump the 1.19 matrix cell to 1.19.5 and the 1.18 OTP pin to 27.3.4.
  • Move GitHub Actions majors to current stables (actions/checkout@v7, actions/cache@v6, actions/upload-artifact@v7) in workflows and examples.
  • Align CI/Hex Postgres service images on postgres:17.

Fixed

  • Avoid OTP 28.0 runtime regex recompilation (performance warning) by running on OTP 28.5.

v0.5.11

Choose a tag to compare

@mward-sudo mward-sudo released this 02 Aug 00:55
c93a04a

Changed

  • Format generated modules once on the write path: Codegen.prepare_directory/4 passes format: false to Output.prepare_write/3 after generate_module/3 has already formatted (avoids a second Code.format_string!/1) (#88).
  • Memoises Postgres OID→type and column-nullability catalog lookups inside Postgres.inferrer/1 for the lifetime of a generate/check pass; plan column sources use tuple indexing instead of Enum.at/2 (#88).

Docs

  • Clarify independence from Gleam Squirrel (not affiliated / endorsed) (#88).
  • Add docs/PERFORMANCE.md, mix bench (bench/micro.exs), and soft CI microbench reporting on the quality matrix cell (summary only; no absolute timing gates) (#88).
  • Add docs/README.md clarifying docs/ (hand-written) vs guides/ (ExDoc guides) vs doc/ (generated, gitignored); split README Guides / Project documentation sections (#88).

v0.5.10

Choose a tag to compare

@mward-sudo mward-sudo released this 02 Aug 00:21
90e20a4

Changed

  • Lower the Elixir requirement to ~> 1.18 (stdlib JSON floor). Recommend Elixir 1.20+ for gradual typing / compiler typechecking; generated Dialyzer @specs remain for Dialyzer on all supported versions (#85).
  • CI matrix compiles and tests on Elixir 1.18, 1.19, and 1.20 (every cell is a hard gate); Dialyzer / Reach / ExDNA / format / Credo stay on 1.20. Hex publish remains on Elixir 1.20 (#85).

Fixed

  • Supervise Postgrex connections in ExUnit setup so Elixir 1.18 does not fail on_exit cleanup with GenServer.stop {:EXIT, :normal} (#85).

v0.5.9

Choose a tag to compare

@mward-sudo mward-sudo released this 01 Aug 23:53
8847e5d

Changed

  • Move SQL directory discovery from Squirrelix.CLI into Squirrelix.Discover (connection parsing stays on CLI); codegen shares TypeMapper.row_typespec/1 for generated row field typespecs (#52).

v0.5.8

Choose a tag to compare

@mward-sudo mward-sudo released this 01 Aug 23:30
89634fc

Changed

  • Make file_system an optional dependency used only by mix squirrelix.gen --watch; missing dep raises a clear install hint (#50).

Fixed

  • Serialize async test compiles of the same generated module name to avoid flaky MyApp.SQL “currently being defined” failures under CI parallelism.

Docs

  • Document the intentional libpq-aligned sslmode=require[verify: :verify_none] mapping and point adopters at verify-ca / verify-full for peer verification (#70).

v0.5.7

Choose a tag to compare

@mward-sudo mward-sudo released this 01 Aug 23:08
56aa32e

Fixed

  • Strip trailing ! / ? nullability override aliases after applying force-nullability (#64)
  • Fail --infer on Postgres < 16 with UnsupportedPostgresVersion (#65)
  • Nested-array encode/decode runtime helpers (#67)

Added

  • Hard-reject multi-statement .sql files; dollar-quote-aware single-statement check (#66)

Docs

  • Soften parity claims; numericDecimal.t() divergence; EXPLAIN nullability fallback (#68, #69)

v0.5.6

Choose a tag to compare

@mward-sudo mward-sudo released this 29 Jul 17:59
3cd3277

Fixed

  • Treat Reach Cross-Function Smell findings as hard failures in CI, Hex Publish, and mix ci (--strict), and set smells: [strict: true] in .reach.exs (#60).
  • Clear Reach smells in Squirrelix.Codegen.Runtime (iolist section join; prepend+reverse for list encode/decode accumulators) (#60).