-
Notifications
You must be signed in to change notification settings - Fork 256
feat: extend the extension to support more version pins #1418
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
base: main
Are you sure you want to change the base?
Conversation
|
Unfortunately its not quite enough as the version name is in the generated repository that the toolchain lives in and so as soon as you switch away from the default versions you will get errors due to unresolved repo names. |
Hm, you mean, specifically, like here? (I'd actually expect that I'd have to keep the register_toolchains list in sync, so maybe that's not unexpected?). I also discovered use_all_repos which provides enough information for |
|
@jsharpe this is the error you meant, right? If so, I put up a solution over here to help keep the list in sync: #1420 (hopefully I understood what you meant?) |
ab96e59 to
3fe201e
Compare
|
Actually, I just realized that I'm not sure this is working as intended. The |
Not quite; the error occurs if you try to actually configure the version. Yes you need to fix the PR #1158 is the more complete fix for these issues which moves the toolchains into a single hub which removes the need to know the versions in the module. I need to update the docs on that PR but other than that I think its ready to go so any testing / another pair of eyes on those changes are gratefully received if you have the bandwidth to do so. |
I actually thought about this a bit more, and my gut says now that the problem is you shouldn't actually register the toolchains in rfcc's MODULE.bazel, except as dev_dependencies- registering a toolchain as a non-dev dependency means it can't be disabled by the root module without patching the dep. (This feels like a wart in the bzlmod api that the root module has no way to prevent the registration of toolchains in deps without patches). I left a bit of a comment about it on the main MR, too: #1158 (comment) |
|
rules_rust appears to have come to a similar conclusion here though the mechanism is different. |
This makes it possible to pin meson, make, and pkgconfig in the same way it was possible with workspaces. I should say: I don't actually know if this is the correct way to do this, I was just following the existing example and it Seems To Work.