-
-
Notifications
You must be signed in to change notification settings - Fork 932
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Option to stop Dioxus CLI from ignoring tooling in PATH #3457
Comments
The version conflict error - that's caused by the wasm-bindgen our CLI installs? If so, that needs fixed asap. Our CLI (v0.6.1) should install the wasm-bindgen version that Cargo reports your project needs. I haven't had issues with this, but perhaps a more complex project setup could cause it to fail. I agree with needing a way to override wasm-bindgen and other systems the CLI uses. |
IDK if that's the case. I am using
I am currently testing against the demo project that On the subject of being able to actually control which wasm-bindgen version is being used, does the PATH method seem reasonable? On the Nix side of things -- almost any method can be made to work -- flags, PATH, specific env vars like Edit: Some of the other Nix users here have spotting an issue with I went ahead and tried out their Regardless, this is kind of off topic for the scope of this feature request. It should also be emphasized that this 'simple' behavior mode I'm proposing probably should not make any assumptions about whether e.g. If that were done, it would be relatively trivial to then get it to build in nix envs, both in impure shells for quick development/prototyping, and strict build environments. |
That Anyway, a better solution to this from the code level will be beneficial. |
Feature Request
As it stands, the
dx
utility is bundled with / automatically fetches its ownwasm-bindgen-cli
that it uses over the environment one. This is certainly useful on imperative systems, but on declarative ones like Nix, it seems actively harmful to get something to work reliably.E.g., I see this message:
I add this to my dev environment:
My Nix development environment is now correctly pinning the wasm-bindgen-cli version:
But
dx
ignores this and stubbornly keeps using the wrong version.Implement Suggestion
It should be possible to pass a simple flag, or environment variable, to override
Dioxus CLI
's behavior, so that rather than trying to handle which dependencies are used, it just trusts the environment (PATH, etc) to be correct. Perhaps a flag like--use-local-tooling
? This ideally would stop any attempt to automatically fetch any external tooling, and instead simply look for it in PATH, and error immediately if needed but not present.That way, reproducible build processes like Nix, Docker, and whatnot, can simply pin their own environment at a specific version, and have it just work.
This would (maybe?) obviate PR #3442, fix issue #3083, and pave the way toward better reproducible CI for all Dioxus apps.
The text was updated successfully, but these errors were encountered: