Skip to content
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

flake modules don't capture the flake attributes #23

Open
zimbatm opened this issue Jul 2, 2024 · 1 comment · May be fixed by #50
Open

flake modules don't capture the flake attributes #23

zimbatm opened this issue Jul 2, 2024 · 1 comment · May be fixed by #50
Labels
enhancement New feature or request

Comments

@zimbatm
Copy link
Member

zimbatm commented Jul 2, 2024

As a publisher, I might want to expose modules that use flake and inputs attributes.

At the moment, those arguments will be filled with values from the consumer flake.

The flake author should be able to reason about the content of these attributes.

=> somehow lock those arguments to contain the values of the publisher flake

@zimbatm zimbatm added the enhancement New feature or request label Jul 2, 2024
@phaer
Copy link
Member

phaer commented Dec 6, 2024

This would be really useful!

I think the first problem is that we are currently exposing modules in the publisher flake simply as a store path.
Changing that to export a function/module directly could make it easier to bind inputs and flake right in the publisher flake.

lib.modules.importApply could be a good fit, but would require taking two positional arguments in a module instead of just one.

Would be even better to be able to avoid this, but this would probably require a way to to partially apply the module, in such a way that the wrapped module still has the right builtin.functionArgs for evalModules to work correctly. I don't know how to that

phaer added a commit to phaer/blueprint that referenced this issue Dec 6, 2024
@phaer phaer linked a pull request Dec 6, 2024 that will close this issue
phaer added a commit to phaer/blueprint that referenced this issue Dec 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants