Skip to content

Remove stale untracked lib/python/base_cli/ __pycache__ cruft #1995

Description

@codeforester

Goal

Remove the stale, untracked lib/python/base_cli/ directory (currently only
__pycache__ files with no source) left over from before base-cli was
extracted into its own PyPI package.

Background

lib/python/base_cli/ in the working tree contains only compiled
__pycache__/*.pyc files across several CPython versions and an empty
tests/ directory — there is no .py source anywhere under it, and
git ls-files lib/python/base_cli/ returns nothing, confirming it was never
tracked. Base now correctly resolves base_cli via the published
base-cli==0.4.2 dependency in requirements-dev.txt. This leftover
directory is harmless today, but a stray untracked package directory sitting
under a path that can end up on PYTHONPATH is exactly the kind of thing
that causes a confusing import-shadowing bug later, and it adds noise for
anyone inspecting lib/python/.

Scope

  • Delete lib/python/base_cli/ (and its __pycache__/tests contents) from
    the working tree.
  • Confirm no build, test, or PYTHONPATH-construction logic references this
    path expecting it to exist locally (it should not, since it was never
    tracked and the real dependency comes from the installed base-cli
    package).

Acceptance Criteria

  • lib/python/base_cli/ no longer exists on disk after a clean checkout
    and a normal basectl setup / test run.
  • basectl test base and the standalone Python test command in
    CONTRIBUTING.md still pass unchanged, confirming nothing depended on
    the stale local path.

Validation

  • basectl test base
  • BASE_CLI_SOURCE_DIR=../base-cli/lib/python PYTHONPATH=../base-cli/lib/python:lib/python:cli/python python -m pytest
  • git status to confirm the directory was untracked before removal (no
    tracked files are being deleted)

Non-Goals

  • Does not change how Base depends on base-cli (still base-cli==0.4.2 via
    requirements-dev.txt).
  • Does not touch the standalone base-cli source checkout used for
    from-source Python testing per CONTRIBUTING.md.

Project Fields

Status: Backlog · Priority: P3 · Size: T · Area: Python · Initiative: Contract Hardening

Agent Assignment

Copilot candidate after triage

Metadata

Metadata

Assignees

Labels

enhancementNew feature or product improvement

Type

No type

Projects

Status
Backlog

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions