Conversation
There was a problem hiding this comment.
Pull request overview
This PR improves reliability of enum handling during Elm SDK generation and makes the project easier to build/test consistently in CI and via Nix flakes.
Changes:
- Fix named-enum lookup to be order-insensitive by sorting enum variant keys before dictionary lookup.
- Add a regression test ensuring named enum query params use enum-to-string helpers even when enum variant order differs.
- Update build tooling: introduce a Nix flake-based build (with Elm dep pinning artifacts), adjust Volta’s Node pin, and expand CI triggers.
Reviewed changes
Copilot reviewed 5 out of 6 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
tests/Test/OpenApi/Generate.elm |
Adds regression test for enum query params + new expectOccurrenceCount helper. |
src/CliMonad.elm |
Sorts enum variants before lookup to match how enums are keyed during extraction. |
package.json |
Updates Volta pinned Node version. |
flake.nix |
Reworks flake to build the CLI with Bun + Elm deps via fetchElmDeps, and exposes packages/apps. |
cli/registry.dat |
Adds Elm package registry data needed for reproducible Elm dependency fetching in Nix. |
cli/elm-srcs.nix |
Adds pinned Elm dependency sources/hashes for Nix builds. |
.gitignore |
Ignores result symlink from nix build. |
.github/workflows/ci.yaml |
Runs CI on pushes to main in addition to PRs. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
46941e1 to
0dbf2e5
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.