Conversation
Add a Flox (Nix-based) environment as an alternative to `make tools-setup` for setting up development dependencies. The manifest mirrors all tools from `tools/setup-tools` and `.settings.yaml`. Update DEVELOPMENT.md with Flox usage instructions and a prompt for keeping the Flox manifest in sync when `.settings.yaml` tool versions change.
Coverage Report ✅
Coverage BadgeNo Go source files changed in this PR. |
There was a problem hiding this comment.
We had Flox before as an alternative and since it was really used by one contributor it often lagged behind the frequently evolving main settings approach that allows the entire project (dev and CI/CD side to sync on versions while enable different deployment mechanism).
Some of the constraints on the GH actions that can be used in NVIDIA org means that the CI side for Flox also had to do some non-idiomatic stuff installation/updates). Even in this PR you can already see the coverage gaps between manifest.toml and .settings.yaml. The manifest claims to mirror .settings.yaml, but they're out of sync:
| Tool | In .settings.yaml |
In manifest.toml |
Notes |
|---|---|---|---|
| kwok | ✅ v0.7.0 |
❌ missing | Used by make kwok-test-all |
| karpenter | ✅ v1.8.0 |
❌ missing | |
| hugo | ✅ 0.155.3 |
❌ missing | Docs builds |
| node | ✅ 22 |
❌ missing | Docs builds |
| awscli2 | ❌ not listed | ✅ present | Where does this come from? |
A developer running flox activate would be missing tools that make tools-setup provides, which undermines the "drop-in alternative" claim.
Also, the DEVELOPMENT.md currently says .settings.yaml changes "propagate everywhere automatically." That's no longer true with Flox — the manifest requires manual updates. The sync instructions ("use an AI assistant prompt") are creative but fragile. Maybe could either:
- Generating
manifest.tomlfrom.settings.yaml(a script intools/that templates it), or - Being explicit in the docs that Flox is best-effort and may lag behind
make tools-setup
Version pinning
Only Go has a version constraint (^1.26). Every other tool is unpinned in the manifest — the lock file pins them, but flox update would pull whatever's latest in nixpkgs, potentially mismatching .settings.yaml. Adding version constraints (even just major version) would reduce surprise drift.
Housekeeping
Per project policy, please remove the "Generated with Claude Code" line from the PR description (see CLAUDE.md).
Summary
Larger, meta point, given the early stage of this project and the velocity with which it evolves, we want to keep things as aligned to the default, idiomatic OSS Go project experience.
I’m looking at projects like Kubernetes, Helm, Terraform, Docker, or Prometheus and I am not seeing any of them using Flox. While Flox does have some nice properties, unless we have consensus from other maintainers in this project to use Flox themselves and ensure ongoing support, I'm incline to recommend we hold back on introducing yet another tool for now.
I am in agreement with @mchmarny |
|
Sounds good - it was useful to me and thus I wanted to share. We can close this and hopefully revisit it once Flox/Nix are in more widespread usage. It is incredibly useful to have an isolated environment for installing all these tools without conflicting with the requirements of other projects developers work on. |
Add missing tools (kwok, hugo, nodejs), pin package versions, remove awscli2, and fix DEVELOPMENT.md to clarify Flox is best-effort and requires manual sync with .settings.yaml.
|
Re-opening 🙏 - I have made a best effort to address the feedback @mchmarny / @dims - if this is sufficient, please consider merging, if not I am ok if we want to close the PR and address it at a later date. Aside from that, if I may offer my opinion: I understand introducing a new paradigm for environment management is not a trivial thing, but the industry is indeed moving this direction and it is in part our duty to innovate. Ideally we would use Flox OSS for all environments across dev/CI rather than maintain shell scripts that do not provide an isolated environment. For those unfamiliar - Flox provides Python Virtualenv-like environments for all dev/ci dependencies while guaranteeing that the exact build of each tool is used end-to-end in all environments. |
Replace 'flox install' with 'flox activate' in the sync instructions, as activate is what re-resolves the lock from an edited manifest.
|
I want to add my thoughts to this discussion. This week I found and fixed several issues in our current tools-setup, and it's making me wish it were easier to add and test new dependencies. Let me outline the problems I've been running into and how I think Flox could help address them. Issues with the current approach:
Related PRs from this week: |
Add syft package and unpin tilt (0.37 not yet in nixpkgs).
Summary
make tools-setup.flox/env/manifest.tomltracks tools fromtools/setup-toolsand.settings.yamlon a best-effort basisflox activatecommandDEVELOPMENT.mdwith Flox usage instructions and guidance for keeping the manifest in sync with.settings.yamlTest plan
flox activate -- make tools-checkverifies tools are available