mtkennerly / poetry-dynamic-versioning

Plugin for Poetry to enable dynamic versioning based on VCS tags
MIT License
607 stars 35 forks source link

poetry publish can't find files built with with dynamic versioning #167

Closed JohnPaton closed 7 months ago

JohnPaton commented 7 months ago

Similar to this discussion, I am running a CI/CD pipeline with separate build and deploy steps, with dist/ passed between them as an artifact. If I use poetry-dynamic-versioning, my build is correctly versioned as configured. However, as pointed out in the linked discussion, poetry publish only looks for builds of the current version to be published, and it's reading the 0.0.0 placeholder. This leads to

$ poetry publish 
No files to publish. Run poetry build first or use the --build option.

despite my dynamically-versioned builds being present in dist/.

JohnPaton commented 7 months ago

Turns out I hadn't enabled the plugin with poetry self add on the publish step. After doing that it was all clear!

Sorry for the noise