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

Ability to import arbitrary python package #1027

Open
jkrzemin opened this issue Aug 18, 2023 · 1 comment
Open

Ability to import arbitrary python package #1027

jkrzemin opened this issue Aug 18, 2023 · 1 comment
Labels

Comments

@jkrzemin
Copy link
Contributor

Describe the bug/feature
In couple of ways, kapitan is loading up python code directly from file (i.e. components, lib). We could extend this feature with an ability to load and execute any python package (as long as it fulfills the interface contract).

This would allow users to version and store those python scripts outside of kapitan inventory and possibly make kapitan even more extendable in future.

Important note is to not drop the current functionality, I think we can achieve that by working with python path.

@MatteoVoges
Copy link
Contributor

Hey @jkrzemin could you explain again what you meant back then, because I think we already support this with the use of kapitan dependencies. For example we have our own generators repository where we independently work on them and even version them and stuff and then fetch the repo via kapitan dependencies to a lib directory where kapitan / kadet can access them.

To give you an update regarding the OmegaConf-resolver modules we talked about: You can import an external module where your resolvers are organized, so you could use the kapitan dependencies approach above. When I start making the OmegaConf features configurable, there will be a cli / .kapitan flag --resolvers_path, where kapitan searches for the resolvers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants