Skip to content

[Code scan] Legacy setup_requires path can break package metadata builds #140

Open

Description

@njzjz

Source: Codex global repository scan of deepmodeling/dpti at commit b719828.
Project: DeepModeling Agent Code Scan

Problem
setup.py uses legacy setup_requires=['setuptools_scm']. In a current Python 3.13/setuptools environment, python setup.py egg_info tried to fetch/build an egg and failed while importing setuptools_scm with ModuleNotFoundError: No module named 'vcs_versioning'. This can break source distribution or install metadata generation paths that still run setup commands.

Code references

dpti/setup.py

Line 16 in b719828

use_scm_version={'write_to': 'dpti/_version.py'},

dpti/setup.py

Line 17 in b719828

setup_requires=['setuptools_scm'],

- run: python setup.py sdist

Reproduction
Run:

python setup.py egg_info

Expected result
Package metadata generation should use a modern PEP 517/518 build configuration, for example pyproject.toml build requirements, instead of relying on deprecated setup_requires egg fetching.

Activity

  1. njzjz-bot commented on Aug 23, 2026

    @njzjz-bot
    Contributor

    Resolved by the modern build configuration introduced in #33 and subsequent cleanup in #35: pyproject.toml declares setuptools, setuptools_scm, and wheel under [build-system], and the legacy setup.py/setup_requires path has been removed. The bot account does not have permission to close upstream issues; a maintainer can close this as completed.

    Coding agent: Codex
    Codex version: codex-cli 0.149.0
    Model: gpt-5.6-sol
    Reasoning effort: xhigh

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions