feat: restore self-modification loop (Fixes #983)
Restores the branch→edit→test→commit/revert loop deleted in
Operation Darling Purge (commit 584eeb679e).
New package: src/self_coding/
- self_modify/loop.py — SelfModifyLoop: creates a self-modify/<slug>
branch, runs an edit callable, gates commits on pytest -x -q, reverts
on failure, then opens a Gitea PR via the REST API.
- gitea_client.py — thin GiteaClient wrapper (create_pull_request,
add_issue_comment); degrades gracefully when token absent or network
unreachable.
Tests: tests/self_coding/test_loop.py (15 unit tests, all passing).
All 451 unit tests green; lint clean.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
7
src/self_coding/__init__.py
Normal file
7
src/self_coding/__init__.py
Normal file
@@ -0,0 +1,7 @@
|
||||
"""Self-coding package — Timmy's self-modification capability.
|
||||
|
||||
Provides the branch→edit→test→commit/revert loop that allows Timmy
|
||||
to propose and apply code changes autonomously, gated by the test suite.
|
||||
|
||||
Main entry point: ``self_coding.self_modify.loop``
|
||||
"""
|
||||
Reference in New Issue
Block a user