Open
Description
Hi Jonas,
I have an issue during the install of the new version of config2 (0.3.2).
It seems that there is an issue with the requirements of the mybad module.
Please find attached the log file (clean install from a docker image).
$ pip install config2
[...]
Collecting mybad>=0.1.4 (from config2)
Downloading https://files.pythonhosted.org/packages/fb/62/5366bda200b009452f4446ade7758f0a18be21a3131ca5e541d4b07e6d4e/mybad-0.2.0.tar.gz
ERROR: Complete output from command python setup.py egg_info:
ERROR: Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-s_jj15d_/mybad/setup.py", line 8, in <module>
import setupextras
ModuleNotFoundError: No module named 'setupextras'
Thank you for your help (and for the package ;))!
Jean-Baptiste
Activity
grimen commentedon Jun 11, 2019
I haven't been able to reproduce this.
@jblereste Any way you could provide a shell script that reproduces this?
jblereste commentedon Jun 11, 2019
setupextras module is guilty!
I attached these two scripts (using a fresh python install with docker)
not-working.txt
working.txt
grimen commentedon Jun 12, 2019
@jblereste Oh this sucks, works with clean virtualenv (where no deps are installed) but fails when I run your example. So
setup.py
is not allowed to import any dependencies defined inrequirements.txt
...Python/PIP is so broken by design. :/I either have to hardcode all these functions in 15 modules, or require
setupextras
. I don't know what is best/worst right now.bjoluc commentedon May 25, 2020
@grimen Looks like using Poetry would automatically solve this one as well.
reuben commentedon Apr 26, 2022
You can setup a
pyproject.toml
file with the following contents:reuben commentedon Apr 26, 2022
PRs here: grimen/python-mybad#1 and here: #22
mtr commentedon Sep 21, 2022
I would really love it if you could include the PR @reuben provides. That would solve a similar problem I experience using
pipenv
.mrsouthern commentedon Nov 4, 2022
Please.
swarupe04 commentedon Sep 3, 2023
Any update on this or any alternative option?
sdg002 commentedon Oct 6, 2023
Similar problem. I was eagerly looking forward to introduce this library to my team.
Version of Python
3.9
Structure of requirements.txt
Error message while trying to install setupextras
bjoluc commentedon Oct 18, 2023
Sorry to hijack a thread on this project again – I just couldn't resist to reply: @swarupe04 @sdg002 I wrote appcfg a few years ago as a simple, fully tested alternative to this and I'll keep maintaining it too (should you be worried about that). Unlike with config2, the root path is inferred from
__name__
instead of the file system and the configuration is returned as a plain Python dict which you can always wrap in DotDict or friends if the dot syntax is important to you. Cheers!