-
Notifications
You must be signed in to change notification settings - Fork 204
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
feat: Add the project itself as an editable dependency #1084
Conversation
Would this also work for projects that are compiled with maturin for example? |
If you would specify that correctly in the |
Would be nice if pixi read the |
Note this does not seem to work currently running then then yields a |
I just tested maturin with the regular editable install feature from
Seems like |
Maybe having an option to turn off automatically adding |
@pavelzw , does automatic recompilation work with |
yeah it looks like maturin doesn't work that way. maybe adding somewhere in the docs that you should disable this feature (using |
We can also add a flag or maybe a boolean to always rebuild, although it does kind of have a bit of feature overlap with the |
@olivier-lacroix seems main wasn't merged in this branch yet, so there were no editable installs at all 😄 I've merged main and added some small changes. Hope you dont't mind me pushing on this. I believe it should now work. Also maybe we should use a proper more python directory structure for this example, even though this works with Even setuptools recommends having a seperate source folder: https://hatch.pypa.io/latest/plugins/builder/wheel/#default-file-selection |
Also, do we need to expand the CLI to include installing the local editable projects with extra's? |
🤦 Indeed, it works :-) |
Yeah. I have reorganised the folder into a proper python package |
@pavelzw , I do not see the harm in having it installed as editable, even without the rebuild trigger? |
Yes maybe. Also, in #1077, I propose to create pixi features & environments based on the extras automatically, which is another way to provide that feature |
Quick question @tdejager , I see the source dependency includes a sha256 in the lock file: when is this value re-rendered? In case that lockfile is used in a dockerfile, it may be useful to be able to opt-out of recording that hash: otherwise, you cannot cache the layer containing all the dependencies if the hash has changed. what do you think? |
0310421
to
01882a4
Compare
This is regenerated when the lock file is invalidated, I think there is the '--frozen' flag or something that bypasses this. |
8920c55
to
012d538
Compare
28f1bc5
to
012d538
Compare
I can think of some situations (for example in docker containers) where you would want to install the package in non-editable mode. So having an on/off switch might still help in these cases |
717f5c7
to
35595fe
Compare
Alright. message added @tdejager . I kept it short :-). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry. meant to select Request changes
.
3240863
to
4872965
Compare
4872965
to
22ffc49
Compare
I have added more details in the doc about the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this looks great! WDYT @ruben-arts?
Pushed a fix where it was using a wrong path in the test. Let's see if that solves things. |
@tdejager ,added platforms. now the downstream tests pass, but not the cargo tests on windows! any idea where that error could come from? |
It was passing before: is this just a temporary failure? |
He I've only followed this feature from the side line. What is the conclusion? Do we auto add the project itself or do we initialize with the |
@ruben-arts we initialise with the |
@tdejager , happy with this PR? all tests are 🆗 |
Fixes #1083