Skip to content

[Bug]: Local development setup fails on a fresh clone due to missing setuptools pin #492

Description

@Dimagidhp

Description

On a fresh clone, pip install -r requirements.txt succeeds but
python -m mkdocs build fails with:

ModuleNotFoundError: No module named 'pkg_resources'

markdown==3.2.1 requires pkg_resources, which setuptools removed in
version 82.0.0. setuptools is not pinned in en/requirements.txt, so pip
installs the latest version.

The Dockerfile already pins setuptools<80, so container builds are fine —
only local setup is broken. Existing contributors don't see this because their
virtual environments already have an older setuptools.

Fix: add setuptools<80 to en/requirements.txt to match the Dockerfile.

Steps to Reproduce

  1. Clone the repository:
   git clone https://github.com/wso2/docs-api-platform.git
  1. Create and activate a virtual environment:
   cd docs-api-platform
   python3 -m venv venv
   source venv/bin/activate
  1. Install the dependencies:
   cd en
   pip install -r requirements.txt
  1. Build the site:
   python -m mkdocs build

Result: the build fails with:

   File ".../site-packages/markdown/core.py", line 26, in <module>
       import pkg_resources
   ModuleNotFoundError: No module named 'pkg_resources'

Version

main @ 5aab8ab

Environment Details (with versions)

OS: Ubuntu 24.04
Python 3.12.11, pip 26.2.1, setuptools 84.0.0, markdown 3.2.1, mkdocs 1.4.2

Activity

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

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions