You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On 31 October (in 12 days), python-dotenv's build script will stop working as setuptools drops support for invoking python setup.py. Read this blog post about why.
The simple fix is to switch to building with build (which uses PEP 517 to build the sdist and wheel) instead of calling python setup.py (and installing setuptools).
A further improvement is to explicitly declare the build backend and requirements in pyproject.toml:
It's not necessary to move the project metadata and build configuration to pyproject.toml, although that would be a further improvement, allowing for it all to become declarative; setuptools even supports the dynamic version and combined long-description files currently in python-dotenv's setup.py.
Thanks @EpicWink for the patch - it looks simple enough.
That said, in an ideal world we should move to using pyproject.toml. I'm not quite sure about any backward compatibility impact this might have, so if anyone has insights, please share.
@EpicWink, if you have time, would you be able to create a pull request? I'm also happy to make the changes myself if that's easier.
I'm not quite sure about any backward compatibility impact this might have, so if anyone has insights, please share.
The earliest version of setuptools which supports metadata in pyproject.toml only supports Python 3.7+. #583 uses a version which only supports Python 3.9+ (which is fine).
Main compatibility us that python setup.py fails, which is going to fail in a couple of weeks anyway (unless setuptools version is constrained in #582).
Activity
theskumar commentedon Oct 14, 2025
Thanks @EpicWink for the patch - it looks simple enough.
That said, in an ideal world we should move to using
pyproject.toml. I'm not quite sure about any backward compatibility impact this might have, so if anyone has insights, please share.@EpicWink, if you have time, would you be able to create a pull request? I'm also happy to make the changes myself if that's easier.
EpicWink commentedon Oct 15, 2025
See #581, #582, or #583
The earliest version of setuptools which supports metadata in pyproject.toml only supports Python 3.7+. #583 uses a version which only supports Python 3.9+ (which is fine).
Main compatibility us that
python setup.pyfails, which is going to fail in a couple of weeks anyway (unless setuptools version is constrained in #582).EpicWink commentedon Oct 31, 2025
#583 was accepted