Skip to content

Test the newest Nx release in CI - #56

Open
reidmorrison wants to merge 2 commits into
elixir-nx:mainfrom
reidmorrison:ci-nx-latest
Open

reidmorrison wants to merge 2 commits into
elixir-nx:mainfrom
reidmorrison:ci-nx-latest

Conversation

@reidmorrison

@reidmorrison reidmorrison commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

Follow-up to #54. CI only tests the Nx version in mix.lock (0.6.2), so problems that only show up on newer Nx go unnoticed. For example, since Nx 0.8 Nx.stack/2 calls the backend's stack directly, which Ortex doesn't implement yet (fixed in #57).

This adds an "Nx latest" variant of the Linux job that runs mix deps.update nx --only test (which also updates Nx's own dependencies, such as complex) before fetching dependencies. Both variants now run mix deps.get --only test, because the dev-only exla and torchx 0.6 still require Nx 0.6 and would otherwise block resolving Nx 1.x. fail-fast: false keeps a failure in one variant from cancelling the other.

I ran both variants' steps locally: all 117 tests pass on Nx 0.6.2 and on Nx 1.0.0.

Code Review.

  • Fixed: unlocking nx complex by hand could quietly resolve an older Nx once a future Nx needs a newer version of another locked dependency. The step now runs mix deps.update nx --only test.
  • Fixed: the new matrix used the default fail-fast, so a failure on Nx latest cancelled the Nx locked run. It now sets fail-fast: false.

CI only tests the Nx version in mix.lock (0.6.2), although Ortex now
allows Nx 1.0. Since Nx 0.8 several operations, such as stack, call
the backend directly, so problems that only show up on newer Nx go
unnoticed.

Add an "Nx latest" variant of the Linux job. It unlocks nx and complex
(Nx 1.x needs complex 1.x) before fetching dependencies. Both variants
now fetch only the test dependencies, because the dev-only exla and
torchx 0.6 still require Nx 0.6 and would block resolving Nx 1.x.
Answers /code-review high of ci-nx-latest at a0bbcda:

- Unlocking "nx complex" by hand lists Nx's dependencies in the workflow.
  If a later Nx needs a newer version of another locked dependency, Hex
  quietly resolves an older Nx and the "latest" leg stops testing the
  newest release. "mix deps.update nx --only test" updates Nx together
  with its own dependencies.
- The new two-leg matrix kept the default fail-fast, so a failure on
  "Nx latest" cancelled "Nx locked". Set fail-fast: false.
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