-
Notifications
You must be signed in to change notification settings - Fork 7
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
Replace "poetry" dependency with "poetry-core" #2
Comments
This is blocked for the moment, on several components:
|
This would be very nice. The issue we ran into is that if you put We needed to move back to the |
@johnthagen As a workaround for the issue I believe that installing poetry using the get-poetry script will prevent it from uninstalling itself from the project environment. I haven't tested this exact scenario, but I had a similar issue in a docker build where my poetry installation existed alongside my project installation, and switching to installing poetry via the script fixed it for me. |
@enpaul Thanks, I suspected something like that would help as well. |
Taking another look at this one. The main blocker here is definitely the lockfile support in poetry-core. Parsing and handling lockfile conditions is something I would really like to avoid having to reimplement for this plugin. That said the other blocker I highlighted above (pip installation support) is something I think we can work around. Poetry is MIT licensed so I think the Once both of those elements are unblocked I can drop the |
Yes, I totally agree with this. I'd never want to ask a package like this to reimplement something that should otherwise be shared with Thanks! |
When running 'poetry remove tox-poetry-installer' in the same env as poetry is installed to, poetry will uninstall itself. This is, obviously, not ideal. This change makes poetry an optional dependency so that the plugin can be installed (and uninstalled) alongside poetry in the same env without breaking the poetry installation. The intention is that the plugin can be installed with the 'poetry' extra when being installed to an isolated environment where poetry is not otherwise available. This is a mitigation of Issue #2 as an alternative to vendorization of the enitre poetry project 😬
@enpaul FYI, on the main README this is checked as complete, even though it looks like actually it was just deferred until the stable release. |
Ah, good catch @johnthagen . I'll update the readme |
Update on this issue: this is currently blocking both the 1.0 release of this plugin and the upgrade to Tox 4 compatibility (as noted elsewhere, there are compatibility issues between the versions of The singular blocker on this right now is lockfile processing in |
poetry-core is a project to produce a lighter weight version of core poetry functionality specifically to better support PEP-517 build systems.
However (based on reading the published goals as of the 1.0 RC1 release) I believe it will also contain all the functionality necessary for this plugin to function.
Using the
poetry-core
package instead ofpoetry
would give this project two main advantages:poetry-core
dependencies are considerably lighter than those ofpoetry
. This was done to speed up the creation of PEP-517 build environments, but here it would reduce the size of this project's dependency chain. Since this is supposed to be a minimalist, lightweight plugin that just bridges the functionality of Tox and Poetry it would be nice if it did not need to install a huge number of dependencies to function.poetry-core
package will provide thepoetry.core
module namespace and replace a decent amount of functionality currently in the mainpoetry
module. This means, at minimum, this plugin will need to be updated to be compatible with Poetry 1.1.0+ (which will usepoetry-core
). However due to the design goals ofpoetry-core
it will, by necessity, have a more stable API than some of the more esoteric elements ofpoetry
that this plugin currently imports. Usingpoetry.core
instead ofpoetry
will reduce the likelihood of future updates to Poetry breaking this plugin.I need to confirm what- if any- functionality of
poetry
that this plugin needs is not included inpoetry-core
and determine how to work around those limitations. At minimum I suspect some of the types that are currently imported will not be available, but I have not confirmed this yet.The text was updated successfully, but these errors were encountered: