Skip to content

Distinguish between libraries and applications #3334

@MartinThoma

Description

@MartinThoma
  • I have searched the issues of this repo and believe that this is not a duplicate.
  • I have searched the documentation and believe that my question is not covered.

Feature Request

When you have a pure application, e.g. a package which is intended not to be imported by other packages, but only to be executed directly (e.g. CLI application, a web service, some GUI program), it would be nice to have reliable installations at the client.

For reliable installations, it is important that the dependencies (including transitive ones) are pinned. They are pinned in the poetry.lock file, but that file is not uploaded / used when a package built with poetry, uploaded to PyPI.org is installed via pip.

My suggestion is:

  • Within [tool.poetry], add is-pure-application: true / false or similar (never-included? no-library?)
  • When this attribute is present and true, then poetry adds the transitive dependencies to the shipped setup.py file
  • Then, when installed via pipx, one can be absolutely certain about what is installed and have way more control about the environment.

I'm uncertain, however, how to deal with the "normal" pip which does not create a virtual environment for such a package. That would be problematic.

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/featureFeature requests/implementations

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions