Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix incompatibility issue with setuptools >= 78 #382

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

romeroyonatan
Copy link

@romeroyonatan romeroyonatan commented Mar 24, 2025

Setuptools deprecated dash-separated settings

From NEWS.rst:

Setuptools no longer accepts options containing uppercase or dash characters in setup.cfg. Please ensure to write the options in setup.cfg using the :wiki:lower_snake_case <Snake_case> convention (e.g. Name => name, install-requires => install_requires). This is a follow-up on deprecations introduced in v54.1.0 (see #1608) and v54.1.1 (see #2592).

Issue

      setuptools.errors.InvalidConfigError: Invalid dash-separated key
      'description-file' in 'metadata' (setup.cfg), please use the underscore
      name 'description_file' instead.

Solution

Rename description-file to description_file
Remove description-file because it is not supported by setuptools pypa/setuptools#4913

Closes #383

@LBWright
Copy link

We are also experiencing this issue and it is blocking a production release.

@romeroyonatan
Copy link
Author

Workarround: Install setuptools < 78 and add --no-build-isolation flag to pip install

pip install 'setuptools<78'
pip install python-quickbooks --no-build-isolation

@lepot311
Copy link

BUMP. This got me on a couple different package dependencies today.

@rondanen
Copy link

Hello! Please feel free to use this forked repo for your deployments in the meantime: https://github.com/kolleno/python-quickbooks/

For example in poetry.toml :
python-quickbooks = { git = "https://github.com/kolleno/python-quickbooks/", branch = "master" }

@tconbeer
Copy link

Thanks so much to @romeroyonatan for pinpointing this issue and providing the work-around.

For anyone using uv, here's a working config for the workaround.

pyproject.toml:

[project]
...
dependencies = [
    # other project deps that can be built independently
]

[project.optional-dependencies]
build-quickbooks = [
    # see https://github.com/ej2/python-quickbooks/issues/383
    "setuptools<78",
]
quickbooks = [
    "python-quickbooks==0.9.11",
]

[tool.uv]
no-build-isolation-package = ["python-quickbooks"]

[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"

bash or workflow file:

uv sync --extra build-quickbooks
uv sync --extra quickbooks
uv run <your script or file>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Incompatibility with setuptools >= 78.0.0
6 participants