python packaging question 

let's say I want to publish two packages to PyPI, one called X and the other called X-purepython. the only difference between the two is a line in setup.py (in the latter, a dependency will be left out of install_requires). is it possible to do this with just one codebase and one setup.py?

(the closest I can figure is to make the package not require the dependency by default, but then use extras_require to have `pip install X[notpurepython]` install the dependency)

Follow

python packaging question 

it would be nice if I could do something like X[purepython], but as far as I can extras_require just lets you add additional dependencies, not *remove* them.

(would like to solve this without having to write any custom code that digs into setuptools internals)

python packaging question 

(also no easy way as far as I can tell to direct setup.py to try as hard as it can to install a dependency but let the installation proceed if the dependency installation fails)

Show thread

python packaging question 

@aparrish what about making "pure" the default, so the extra is an additional req?

Sign in to participate in the conversation
Friend Camp

Hometown is adapted from Mastodon, a decentralized social network with no ads, no corporate surveillance, and ethical design.