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.

tag_build breaks prepare_metadata_for_build_wheel

See original GitHub issue

Previously reported in pypa/pip#9446.

This is similar to #1462, but for PEP 517 hooks, so I’m guessing a similar treatment is needed?

[egg_info]
tag_build = dev

[metadata]
name = pkg
version = 0.1

egg_info works as expected:

$ py -c 'from setuptools import *; setup()' egg_info >/dev/null
$ rg '^Version:' < pkg.egg-info/PKG-INFO 
Version: 0.1.dev0

But not the PEP 517 hook:

$ py -c 'import os; from setuptools.build_meta import *; prepare_metadata_for_build_wheel(os.getcwd())' >/dev/null
$ rg '^Version:' < pkg.dist-info/METADATA 
Version: 0.1.dev0dev

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:1
  • Comments:16 (8 by maintainers)

github_iconTop GitHub Comments

3reactions
zzzeekcommented, Jan 17, 2021

im so impressed you understand how setuptools works thanks for the efforts! i still remember ten years ago when nobody could change anything about it.

1reaction
jaracocommented, Jan 30, 2021

How about this:

[tox]

SQLA_REPO = {env:SQLA_REPO:git+https://github.com/sqlalchemy/sqlalchemy.git}

[testenv]
skip_install = True
deps =
     pytest>4.6
     pytest-xdist
     mock
     sqla13: sqlalchemy@{[tox]SQLA_REPO}@rel_1_3
     sqlamaster: sqlalchemy@{[tox]SQLA_REPO}@master
     sqlalchemy: sqlalchemy>=1.3.0

     cov: pytest-cov
     mako
     python-editor>=0.3
     python-dateutil


     postgresql: sqlalchemy[postgresql]
     mysql: sqlalchemy[mysql]
     mysql: sqlalchemy[pymysql]
     oracle: sqlalchemy[oracle]
     mssql: sqlalchemy[mssql]

I was able to run tox -e sqlalchemy,sqla13,sqlamaster,postgresql with that tox file.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to fix pip package installation error in pycharm windows?
Possible solution : Try to run this command from the system terminal. Make sure that you use the correct version of 'pip' installed...
Read more >
his error originates from a subprocess, and is likely not a ...
12` I am having an error when trying to install the requirements `pip3 install -r requirements.txt` ` Getting requirements to build wheel ......
Read more >
3. How to package a Python
In this chapter we will develop an entire example Python package from beginning-to-end to demonstrate the key steps involved in developing a package....
Read more >
How to Publish an Open-Source Python Package to PyPI
In this tutorial, you'll learn how to: Prepare your Python package for publication; Handle versioning of your package; Build your package and ...
Read more >
PEP 426 – Metadata for Python Software Packages 2.0
Integration and deployment can in turn be broken down into further substeps. Build: the build step is the process of turning a VCS...
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