Skip to content

fix: skip performMaintenance() in dry-run mode - #68

Merged
autogame-17 merged 1 commit into
EvoMap:mainfrom
hendrixAIDev:fix/dry-run-maintenance
Feb 22, 2026
Merged

fix: skip performMaintenance() in dry-run mode#68
autogame-17 merged 1 commit into
EvoMap:mainfrom
hendrixAIDev:fix/dry-run-maintenance

Conversation

@hendrixAIDev

@hendrixAIDev hendrixAIDev commented Feb 21, 2026

Copy link
Copy Markdown
Contributor

Problem

performMaintenance() runs unconditionally during node index.js run --dry-run, causing:

  • 1000+ session logs moved to archive directory
  • Evolver hand sessions deleted

Users expect --dry-run to be read-only with zero file system side effects.

Fix

Guard the performMaintenance() call with IS_DRY_RUN check. When --dry-run is active, maintenance is skipped and a log message is printed instead.

Testing

Before fix:

node index.js run --dry-run
[Maintenance] Found 1113 session logs. Archiving old ones...
[Maintenance] Archived 1063 logs to .../archive

After fix:

node index.js run --dry-run
[Maintenance] Skipped (dry-run mode).

Minimal change: 1 file, 6 insertions, 1 deletion.


Note

Low Risk
Small, localized control-flow change that only affects --dry-run behavior and reduces filesystem side effects.

Overview
--dry-run evolver runs are now read-only with respect to session log maintenance.

src/evolve.js guards the performMaintenance() call behind !IS_DRY_RUN and prints a skip message when dry-run is enabled, avoiding file deletes/moves (including archiving and evolver_hand_ cleanup).

Written by Cursor Bugbot for commit 51a5425. This will update automatically on new commits. Configure here.

performMaintenance() archives session logs and deletes evolver hand
sessions regardless of the --dry-run flag. This causes unexpected
side effects (moving 1000+ session files) when users expect a
read-only dry run.

Guard the call with IS_DRY_RUN check so dry-run mode produces no
file system mutations.
@autogame-17
autogame-17 merged commit a7c4b32 into EvoMap:main Feb 22, 2026
1 check passed
fmw666 pushed a commit that referenced this pull request Mar 2, 2026
Add LKCY33 (PR #21), hendrixAIDev (PR #68), toller892 (PR #149).
Update onthebigtree, voidborne-d, blackdogcat entries with full contributions.

Co-authored-by: LKCY33 <lkcY33@users.noreply.github.com>
Co-authored-by: Hendrix <hendrix.ai.dev@gmail.com>
Co-authored-by: toller892 <1094086026@qq.com>
Co-authored-by: Yewlne <dev@yewlne.com>
fmw666 pushed a commit that referenced this pull request Mar 11, 2026
- PR #68 (hendrixAIDev): guard performMaintenance with IS_DRY_RUN
- PR #26 (onthebigtree): hash hostname in env fingerprint, portable validation paths
- PR #63 (voidborne-d): add 61 unit tests for core GEP modules
- PR #21 (LKCY33): add dotenv path rewrite for public build
- PR #25 (onthebigtree): already applied (currentSleepMs, matchPatternToSignals, max_files)
- Update public.manifest.json: include test/*.test.js, add index.js dotenv rewrite

Co-authored-by: Cursor <cursoragent@cursor.com>
fmw666 pushed a commit that referenced this pull request Mar 11, 2026
Add LKCY33 (PR #21), hendrixAIDev (PR #68), toller892 (PR #149)
to acknowledgments. Update onthebigtree entry with PR #25/#26
contributions. Sync Chinese README.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants