question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Transition to pure PyProject.toml

See original GitHub issue

Discussion about transitioning to pure Pyproject.toml using either setuptools or poetry.

@PhilipVinc Probably a question for another issue, but any chance you guys might consider using a python-poetry based toolchain to manage pyproject.toml? Makes life a bit easier re: dev dependencies, environments, and deployment.

I have a branch to transit plum to a pure setuptools + pyproject.toml (so not poetry) but was waiting for pip to get together and support editable installs. It seems they fixed it a few months ago so might as well open the PR.

This is now much easier to do since plum does no longer use cython.

If you think poetry > setuptools I’d be happy to know what’s the advantage for packaging @tbsexton ?

Issue Analytics

  • State:open
  • Created a year ago
  • Comments:12 (9 by maintainers)

github_iconTop GitHub Comments

1reaction
wesselbcommented, Sep 3, 2022

@tbsexton, I would imagine that fully supporting both a Poetry-supported and non-Poetry dev. workflow might come with a fair amount of overhead.

I guess I was imagining some kind of halfway-house, where you don’t entirely exclude non-Poetry users. E.g., with a workaround to install dev. dependencies without Poetry and the ability to run test without Poetry, someone would be able to put together a PR on their own. This PR would fail CI/CD tests, as you point out, but at that point we could suggest they use Poetry to fix CI/CD and help them in doing so. Not entirely sure about this option. Just brainstorming all possibilites! @PhilipVinc, would you be happy with something along these lines, or would you prefer that development be possible entirely without Poetry too?

0reactions
tbsextoncommented, Sep 2, 2022

@PhilipVinc all awesome points.

I definitely agree w.r.t. v1.2 being new, and I actually didn’t know about generic “groups” until yesterday! 😅 Dev-dependencies have been around since the … beginning? … of poetry, and iirc the “groups” idea just expands on that tooling to make it generalize. I would recommend only using the e.g. poetry add -D sphinx syntax since all poetry users would be able to use that (w/o updating, I believe). Updating does have other benefits for our quality-of-life, like the new(ish) plugin system that lets us use Tiangolo’s (of FastAPI fame) poetry-version-plugin to manage version specification via, say, only the git tag.

@wesselb I guess the key question boils down to some things we could test out amongst ourselves in a new branch or two:

  • does requiring use of poetry by developers add significant overhead (preventing contribution) that outweighs the quality-of-life improvements poetry provides?
  • will the effort of supporting both poetry and non-poetry development workflows reduce overhead (encouraging contribution) enough to outweigh your overhead in continuing to support both workflows (e.g. people submitting pull requests that don’t validate dependencies through, say, poetry.lock, which could fail your ci/cd tests and have no non-poetry solution? just brainstorming here).
Read more comments on GitHub >

github_iconTop Results From Across the Web

Transition your Python project to use pyproject.toml and setup ...
The future of Python packaging is pyproject.toml, and (for now) setup.cfg, based on PEP 518 and (soon) PEP 621.
Read more >
Understanding setup.py, setup.cfg and pyproject.toml in Python
I am primarily interested in cases 3 and 4, and my projects tend to be pure Python so I don't need to worry...
Read more >
Packaging Your Python Code With pyproject.toml - YouTube
Your browser can't play this video. Learn more. Switch camera.
Read more >
dojeda/poetry2conda: Convert pyproject.toml to ... - GitHub
A script to convert a Python project declared on a pyproject.toml to a conda environment. This is not an attempt to move away...
Read more >
there is nothing you can do with pyproject.toml ... - Hacker News
- there is nothing you can do with pyproject.toml that you can't with setup.cfg. E.G: you are not forced to use setuptools to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found