Skip to content

refactor: purge the autoconf-era legacy surface from PyAutoNerves #137

Description

@Jammy2211

Overview

After the autoconfautonerves rename (#135), PyAutoNerves still carries a legacy surface from the pre-rename era. A survey on 2026-07-23 separated it into three genuinely different problems, which this task ships as four independent steps.

The autoconf sightings are not tracked driftgit grep -ril autoconf over tracked files returns nothing. What remains is untracked working-copy cruft, one test that litters the repo root on every run, and four dormant one-shot scripts (two of which are already broken on their own imports).

Plan

  • Delete the untracked rename leftovers (autoconf/, test_autoconf/, autoconf.egg-info/, build/, bad/) from the working copy — no commit needed, but autoconf/ is not inert: it still resolves as a namespace package and shadows imports.
  • Fix the test that regenerates bad/ in the repo root on every run, rather than gitignoring the symptom.
  • Delete the dead EDEN tooling (eden.yaml, scripts/edenise.py) — its driver imports autofit.tools.edenise, which no longer exists in PyAutoFit.
  • Delete the one-shot config-migration tooling (scripts/, priors/, json_prior/generate.py) that bootstrapped the original configs years ago and is wired into no CI and no workspace.
  • Trim PR test: re-anchor the version-handshake test fixtures #136 to its test-fixture half, reverting the __version__ bump that contradicts the wheels+tags-only release model.
  • Close feat: workspace version check via config/general.yaml on every library import #100, which is fully shipped but was never closed on GitHub.
Detailed implementation plan

Affected repositories

  • PyAutoNerves (primary, library)

Branch survey

Repository Current branch Dirty? Claim
./PyAutoNerves main clean unclaimed
./PyAutoFit main clean claimed by testmode-env-drift → descoped

Suggested branch: feature/purge-autoconf-era-legacy
Worktree root: ~/Code/PyAutoLabs-wt/purge-autoconf-era-legacy/

Survey findings

1. Untracked rename leftovers. autoconf/, test_autoconf/, autoconf.egg-info/, build/ and bad/ are all present in the working copy and all untracked. autoconf/ and test_autoconf/ contain only __pycache__ — but they still import:

python -c "import autoconf"
→ _NamespacePath(['/home/jammy/Code/PyAutoLabs/PyAutoNerves/autoconf'])

So they shadow imports rather than sitting inert. build/ and *.egg-info/ are already covered by .gitignore.

2. bad/ is regenerated on every test run. test_autonerves/test_config.py:44 sets BAD_PATH = "bad/path" and test_path_empty calls os.makedirs(BAD_PATH, exist_ok=True) into the CWD, never cleaning up. Deleting the directory without fixing the producer is a no-op.

3. Dead one-shot tooling in scripts/. Four drivers from the original config bootstrap, dormant for years, referenced from no CI and no workspace. Two are already broken:

Script State
edenise.py imports autofit.tools.edeniseremoved from PyAutoFit, raises ImportError
convert_prior_configs.py imports oyamlnot a declared dependency
convert_config.py the .ini → YAML migration, long since run
generate_priors.py CLI over autonerves/json_prior/generate.py, whose only other consumer is its own test

Steps

Step 0 — local cruft (no PR).
rm -rf autoconf/ test_autoconf/ autoconf.egg-info/ build/ bad/. All untracked; nothing to commit.

Step 1 — stop bad/ regenerating.
test_autonerves/test_config.py: move test_path_does_not_exist and test_path_empty onto tmp_path; delete the BAD_PATH constant and the remove_path() helper. Fixes the producer instead of gitignoring the symptom.

Step 2 — remove dead EDEN tooling.
Delete eden.yaml and scripts/edenise.py. This is the PyAutoNerves leg of PyAutoMind/draft/refactor/pyautofit/remove_eden_packaging_tooling.md.

PyAutoFit/eden.yaml is descoped — the branch survey found PyAutoFit claimed by the testmode-env-drift worktree. autofit.tools.edenise is already gone from PyAutoFit main, so only the orphan eden.yaml remains there: a one-file follow-up once that claim releases. The eden draft stays open until then.

Step 3 — remove the one-shot config-migration tooling.
Delete scripts/convert_config.py, scripts/convert_prior_configs.py, scripts/generate_priors.py, autonerves/json_prior/generate.py, test_autonerves/json_prior/test_generate.py, and priors/subconfig.json (a stray output artifact of generate_priors.py). Both scripts/ and priors/ disappear.

Step 4 — sort PR #136.
Force-push the branch with only the test-fixture re-anchor (test_workspace.py, test_setup_colab.py), reverting autonerves/__init__.py to 2026.7.9.1. Rewrite the PR body to describe a fixture cleanup — moving the colab mock off the yanked 2026.7.6.649 — not a version sync.

Key files

  • test_autonerves/test_config.pytmp_path migration (step 1)
  • eden.yaml, scripts/edenise.py — deleted (step 2)
  • scripts/, priors/, autonerves/json_prior/generate.py, test_autonerves/json_prior/test_generate.py — deleted (step 3)
  • autonerves/__init__.py — reverted on the test: re-anchor the version-handshake test fixtures #136 branch (step 4)

Guardrails

Testing approach

Full pytest test_autonerves before each push. For step 1, additionally confirm bad/ is absent from the repo root after a run. For step 3, confirm import autonerves still succeeds and the four json_prior.config exports still resolve.

Related

Original Prompt

Click to expand starting prompt

PyAutoNerves still has some references to autoconf (autoconf folder, test_autoconf). Are we able to clean up the cause of this? Just feels like legacy or drift from the old name. There is also an egg info file i guess we can remove, and the bad folder (prevent that from being made?) and the build folder. There is also python files which I think are now defunct so assess if we can remove them, for example we no longer edenise code so that can go (but check its depedency in autofit) and also converting configs to .ini, generate_priors.py are all things which we used to set up initial configs years ago. Maybe break this task down into logical steps as I've throw different things at you. remove eden.yaml from autonerves. also sort this: #136 and I think we can close this? #100, chekc it again autobrain

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions