Skip to content

Master CI failures#52

Merged
Demonstrandum merged 1 commit into
masterfrom
cursor/master-ci-failures-8be8
Feb 18, 2026
Merged

Master CI failures#52
Demonstrandum merged 1 commit into
masterfrom
cursor/master-ci-failures-8be8

Conversation

@Demonstrandum

Copy link
Copy Markdown
Owner

Motivation for features / changes

All master CI builds (CI, Wheel Prerelease, Nightly Release) were failing at the "Pip package test" step with ModuleNotFoundError: No module named 'pkg_resources'. This occurred because modern virtualenv and pip versions no longer pre-install setuptools in new virtual environments, and setuptools was not being pulled in as a dependency for the installed wheel. The PRs passed previously because the CI runner images had an older pip/virtualenv combination that still bundled setuptools.

Technical description of changes

This PR migrates away from pkg_resources by:

  • Replacing pkg_resources.iter_entry_points() with importlib.metadata.entry_points() in tensorbored/default.py, including a version-aware helper to handle API differences between Python 3.9 and 3.10+.
  • Replacing pkg_resources.parse_version() with packaging.version.Version() in tensorbored/data/server_ingester.py and tensorbored/version_test.py.
  • Updating tensorbored/default_test.py to reflect the new entry point implementation.
  • Removing setuptools from tensorbored/pip_package/requirements.txt.
  • Updating Bazel BUILD files to remove expect_pkg_resources_installed and add expect_packaging_installed where necessary.

Screenshots of UI changes (or N/A)

N/A

Detailed steps to verify changes work correctly (as executed by you)

  1. Identified ModuleNotFoundError: No module named 'pkg_resources' in CI logs for build (tf, 3.9) and build (notf, 3.9) at the "Pip package test" step.
  2. Confirmed setuptools was not present in the pip freeze output during the failing CI step.
  3. Replaced pkg_resources usages with importlib.metadata and packaging.version.
  4. Implemented a version-aware helper for importlib.metadata.entry_points() to support Python 3.9 (dict-like return) and 3.10+ (direct group= kwarg).
  5. Updated relevant test files and Bazel BUILD dependencies.
  6. Removed setuptools from requirements.txt.
  7. Ran black and flake8 to ensure linting compliance.
  8. Verified packaging remains a dependency in requirements.txt.
  9. The ultimate verification will be the passing of the CI builds for this PR.

Alternate designs / implementations considered (or N/A)

Considered the different behaviors of importlib.metadata.entry_points() across Python versions (3.9 vs 3.10+) and implemented a compatibility layer to ensure correct functionality. No other major alternate designs for replacing pkg_resources were considered, as importlib.metadata is the standard library replacement and packaging.version was already an existing dependency.


Open in Cursor Open in Web

The pip smoke tests in CI fail with 'ModuleNotFoundError: No module named
pkg_resources' because modern virtualenv/pip no longer pre-install
setuptools, and setuptools is not reliably pulled in as a wheel dependency.

Replace all pkg_resources usage with stdlib/existing deps:
- default.py: pkg_resources.iter_entry_points -> importlib.metadata.entry_points
  (version-aware helper for Python 3.9 vs 3.10+ API difference)
- server_ingester.py: pkg_resources.parse_version -> packaging.version.Version
  (packaging is already a declared dependency)
- version_test.py: pkg_resources.parse_version -> packaging.version.Version
- Remove setuptools from requirements.txt (no longer needed)

Co-authored-by: Samuel <samuel@knutsen.co>
@cursor

cursor Bot commented Feb 18, 2026

Copy link
Copy Markdown

Cursor Agent can help with this pull request. Just @cursor in comments and I'll start working on changes in this branch.
Learn more about Cursor Agents

@Demonstrandum Demonstrandum marked this pull request as ready for review February 18, 2026 14:19
@github-actions

Copy link
Copy Markdown

Preview Deployment

Status ✅ Running
Live Preview https://Demonstrandum-tensorbored-pr-52.hf.space
Space https://huggingface.co/spaces/Demonstrandum/tensorbored-pr-52
Details
  • Wheel: tensorbored_nightly-2.21.0a20260218-py3-none-any.whl
  • Commit: d1f7e03
  • Build status: success

@Demonstrandum Demonstrandum merged commit c9e688b into master Feb 18, 2026
13 checks passed
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.

2 participants