@giamme/forge 0.17.0 → 0.19.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +57 -0
- package/README.md +1 -0
- package/SKILL.md +32 -5
- package/VERSION +1 -1
- package/docs/artifacts.md +33 -1
- package/docs/commands.md +147 -16
- package/docs/dataset.md +5 -0
- package/docs/decomposed-runs.md +122 -1
- package/docs/development.md +2 -1
- package/docs/forge-ui.md +98 -8
- package/docs/memory.md +27 -4
- package/docs/models.md +8 -0
- package/docs/reviews.md +122 -0
- package/docs/safety.md +8 -0
- package/forge +44 -4
- package/package.json +2 -1
- package/references/dataset.md +39 -1
- package/references/decompose.md +737 -16
- package/references/harnesses.md +18 -3
- package/references/planning.md +43 -14
- package/references/solo.md +2 -1
- package/references/ui.md +56 -6
- package/registry.tsv +8 -3
- package/scripts/forge-artifact.sh +14 -0
- package/scripts/forge-brief.py +217 -0
- package/scripts/forge-compare.py +13 -2
- package/scripts/forge-config.py +176 -9
- package/scripts/forge-contract.py +246 -28
- package/scripts/forge-control.py +200 -15
- package/scripts/forge-dispatch.sh +48 -15
- package/scripts/forge-du.py +167 -0
- package/scripts/forge-group.py +496 -0
- package/scripts/forge-groups.py +89 -0
- package/scripts/forge-handoff.py +1128 -0
- package/scripts/forge-lib-adopt.sh +1 -0
- package/scripts/forge-lib-group.sh +641 -0
- package/scripts/forge-lib-plans.sh +343 -4
- package/scripts/forge-lib-review.sh +29 -1
- package/scripts/forge-lib-task.sh +197 -4
- package/scripts/forge-memory.sh +245 -3
- package/scripts/forge-metrics.sh +7 -3
- package/scripts/forge-parallel-options.sh +4 -0
- package/scripts/forge-parallel.sh +1216 -41
- package/scripts/forge-planner.py +104 -8
- package/scripts/forge-prompt.py +120 -0
- package/scripts/forge-retro.py +115 -0
- package/scripts/forge-route.py +190 -12
- package/scripts/forge-runs-compact.py +443 -0
- package/scripts/forge-runs-rm.py +2 -0
- package/scripts/forge-runs.py +27 -8
- package/scripts/forge-schedule.py +633 -49
- package/scripts/forge-shadow.py +7 -1
- package/scripts/forge-solo.sh +4 -0
- package/scripts/forge-summarize.py +698 -0
- package/scripts/forge-ui-options.sh +10 -0
- package/scripts/forge-worktrees.py +243 -0
- package/scripts/forge_brief/__init__.py +831 -0
- package/scripts/forge_brief/answers.py +506 -0
- package/scripts/forge_brief/proposals.py +1630 -0
- package/scripts/forge_dataset/__init__.py +10 -0
- package/scripts/forge_dataset/efforts.py +4 -3
- package/scripts/forge_dataset/export.py +36 -10
- package/scripts/forge_dataset/facts.py +8 -4
- package/scripts/forge_dataset/forecast.py +8 -18
- package/scripts/forge_dataset/harvest.py +241 -12
- package/scripts/forge_dataset/history.py +13 -6
- package/scripts/forge_dataset/importer.py +65 -1
- package/scripts/forge_dataset/names.py +66 -0
- package/scripts/forge_dataset/reviewers.py +5 -2
- package/scripts/forge_dataset/risk.py +6 -3
- package/scripts/forge_dataset/routing.py +6 -1
- package/scripts/forge_decide/__init__.py +11 -1
- package/scripts/forge_groups/__init__.py +308 -0
- package/scripts/forge_groups/attribute.py +289 -0
- package/scripts/forge_groups/review.py +286 -0
- package/scripts/forge_locations.py +366 -0
- package/scripts/forge_owner.py +152 -0
- package/scripts/forge_registry.py +19 -0
- package/scripts/forge_retro/__init__.py +417 -0
- package/scripts/forge_retro/issues.py +1193 -0
- package/scripts/forge_retro/report.py +671 -0
- package/scripts/forge_side/__init__.py +482 -0
- package/scripts/forge_storage.py +515 -0
- package/ui/README.md +68 -8
- package/ui/docs/api.md +375 -31
- package/ui/forge_ui/control.py +451 -11
- package/ui/forge_ui/executions.py +8 -1
- package/ui/forge_ui/export.py +53 -7
- package/ui/forge_ui/groups.py +264 -0
- package/ui/forge_ui/links.py +337 -0
- package/ui/forge_ui/models.py +125 -10
- package/ui/forge_ui/projects.py +4 -1
- package/ui/forge_ui/reader.py +919 -45
- package/ui/forge_ui/server.py +4 -0
- package/ui/forge_ui/static/app.js +173 -11
- package/ui/forge_ui/static/briefview.js +605 -0
- package/ui/forge_ui/static/checksview.js +6 -2
- package/ui/forge_ui/static/controls.js +5 -0
- package/ui/forge_ui/static/diffview.js +86 -1
- package/ui/forge_ui/static/groupsview.js +332 -0
- package/ui/forge_ui/static/index.html +4 -0
- package/ui/forge_ui/static/panel.js +394 -8
- package/ui/forge_ui/static/projectsview.js +189 -10
- package/ui/forge_ui/static/runmodel.js +27 -4
- package/ui/forge_ui/static/storageview.js +352 -0
- package/ui/forge_ui/static/style.css +176 -6
- package/ui/forge_ui/static/worktreesview.js +235 -14
- package/ui/forge_ui/storage.py +150 -0
- package/ui/forge_ui/transcripts.py +35 -10
- package/ui/forge_ui/worktrees.py +154 -13
package/scripts/forge-shadow.py
CHANGED
|
@@ -233,7 +233,7 @@ def run(args) -> int:
|
|
|
233
233
|
signal.signal(signal.SIGTERM, _stop)
|
|
234
234
|
plan = Path(args.plan)
|
|
235
235
|
parent = os.getppid()
|
|
236
|
-
status, out, spec, why = 'skipped', None, None, None
|
|
236
|
+
status, out, spec, why, review = 'skipped', None, None, None, None
|
|
237
237
|
try:
|
|
238
238
|
if os.environ.get('FORGE_FRACTAL_RUN') or not sampled(plan, args.task, args.attempt, rate_of(plan)):
|
|
239
239
|
return 0
|
|
@@ -275,6 +275,12 @@ def run(args) -> int:
|
|
|
275
275
|
if out is not None:
|
|
276
276
|
write(out / 'shadow.error', '%s: %s\n' % (type(error).__name__, error))
|
|
277
277
|
finally:
|
|
278
|
+
# The verdict is read and the snapshot checked: nothing uses the snapshot again (#139).
|
|
279
|
+
if review is not None:
|
|
280
|
+
try:
|
|
281
|
+
bash('forge_drop_snapshot', str(review))
|
|
282
|
+
except Exception: # a leftover snapshot never costs the shadow its status
|
|
283
|
+
pass
|
|
278
284
|
if out is not None:
|
|
279
285
|
write(out / 'shadow.status', status + '\n')
|
|
280
286
|
dataset_event(out, args.task, dict(status=status, attempt=args.attempt, reviewed=args.reviewed,
|
package/scripts/forge-solo.sh
CHANGED
|
@@ -277,6 +277,7 @@ fi
|
|
|
277
277
|
[ "$DRY" = 1 ] || forge_repo_identity "$REPO" "$RUN"
|
|
278
278
|
# Every real run, --ui or not: forge-ui's view of this repo's runs reads the registry.
|
|
279
279
|
[ "$DRY" = 1 ] || forge_ui_register "$RUN"
|
|
280
|
+
[ "$DRY" = 1 ] || forge_storage_check "$RUN" "$REPO"
|
|
280
281
|
# Recorded before any dispatch: forge-ui opens this dir immediately, and a re-run
|
|
281
282
|
# that dies early must not keep showing the previous invocation's verdict.
|
|
282
283
|
if [ "$DRY" != 1 ]; then
|
|
@@ -355,12 +356,15 @@ git -C "$REPO" diff --binary "$START" "$END" -- . ':(exclude).forge' > "$RUN/cha
|
|
|
355
356
|
if [ ! -s "$RUN/changes.diff" ]; then
|
|
356
357
|
# An exit-0 harness with an empty final message and no changes never really ran.
|
|
357
358
|
grep -qx 'class=empty' "$RUN/dwarf.infra" 2>/dev/null && die "the dwarf returned nothing (empty output, no changes) — an infrastructure failure, not a refusal; fix the cause and run again (see $RUN/dwarf.infra)" 8
|
|
359
|
+
# Nor did one its CLI cancelled before it changed anything.
|
|
360
|
+
grep -qx 'class=cancelled' "$RUN/dwarf.infra" 2>/dev/null && die "the dwarf was cancelled by its CLI before it changed anything — an infrastructure failure, not a refusal: $(sed -n 's/^detail=//p' "$RUN/dwarf.infra"); fix the cause and run again (see $RUN/dwarf.infra)" 8
|
|
358
361
|
note "the dwarf produced no changes at all — see $RUN/dwarf.last for what it said"
|
|
359
362
|
echo NOCHANGES > "$RUN/verdict"
|
|
360
363
|
exit 5
|
|
361
364
|
fi
|
|
362
365
|
|
|
363
366
|
REVIEW="$RUN/review-$(date +%s)-$$"
|
|
367
|
+
FORGE_REVIEW_SNAPSHOT="$REVIEW" # forge_metric_begin's EXIT trap removes it, whatever the outcome (#139)
|
|
364
368
|
forge_review_snapshot "$REPO" "$START" "$END" "$REVIEW" || die "cannot create review snapshot" 3
|
|
365
369
|
forge_review_deps "$REPO" "$REVIEW" "$RUN/review.deps"
|
|
366
370
|
SOURCE_FP="$(forge_fingerprint "$REPO")" || exit 3
|