@jesdi/skills 0.0.94 → 0.0.95

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.
@@ -228,7 +228,7 @@ def test_a_fix_batch_is_named_per_commit_and_a_commit_with_no_owner_is_a_violati
228
228
  assert rig.led("End of run: BLOCKED at the fix batch: commits.0.sha") # `$HEAD~1` is no SHA: a second violation
229
229
  reviewed = rig.final()["reviewed"]
230
230
  assert rig.branch() == reviewed, "the rejected commits are off the branch"
231
- (line,) = rig.led(f"End of run: the fix batch was rejected, so the driver moved feat/csv back to its reviewed tip {reviewed[:7]}")
231
+ (line,) = rig.led(f"End of run: the fix batch was rejected, so the driver moved feat/csv back to its pre-batch tip {reviewed[:7]}")
232
232
  left = line.split("the commits of the batch end at ")[1].split()[0]
233
233
  assert git(rig.repo, "log", "--format=%s", f"{reviewed}..{left}").split("\n")[:2] == ["escape quotes", "quote commas"]
234
234
  assert line.endswith("The files of the fixer stay in slot 1 as they are.")
@@ -263,7 +263,7 @@ def test_a_fixer_that_times_out_twice_keeps_its_files_and_the_branch_stays_at_th
263
263
  assert rig.code == 2 and rig.pushes() == [] and rig.branch() == reviewed, rig.out
264
264
  assert decisions(rig)["questions"][0]["id"] == "final-ticket-blocked-1"
265
265
  assert (rig.repo / "wip.txt").read_text() == "half done\n"
266
- assert rig.led(f"End of run: the fix batch was rejected, so the driver moved feat/csv back to its reviewed tip "
266
+ assert rig.led(f"End of run: the fix batch was rejected, so the driver moved feat/csv back to its pre-batch tip "
267
267
  f"{reviewed[:7]}; the fixer made no commit. The files of the fixer stay in slot 1 as they are.")
268
268
 
269
269
 
@@ -306,14 +306,14 @@ def test_a_lens_that_changes_the_slot_twice_ends_the_run_with_a_clean_slot(tmp_p
306
306
  assert rig.code == 0 and rig.pushes() == [f"refs/heads/feat/csv {tip}"], rig.out
307
307
 
308
308
 
309
- def test_a_red_gate_on_the_tidied_tip_stops_before_the_final_review(tmp_path):
309
+ def test_a_red_gate_on_the_tidied_tip_repairs_then_parks_before_review(tmp_path):
310
310
  rig = Inside(tmp_path, ONE, gate={"red": ["feat/csv"]})
311
- rig.run(plan(), *UNATTENDED)
312
- assert rig.code == 1 and not rig.final_calls("final-spec") and rig.pushes() == [], rig.out
313
- assert rig.led("End of run: BLOCKED at the gate: the full gate is red on " + rig.branch()[:7])
314
- assert stage(rig) == {"stage": "implement", "status": "blocked", "blocked": ["final"]}
315
- # The fast gate of the ticket tip, the full gate of its fast-forward, and the full gate of the tidied tip.
316
- assert rig.state()["run"]["gates"] == {"fast": 1, "full": 2} and "| full gates run | 2 |" in rig.out
311
+ rig.run(plan(**{"final/fixer": [fixer("fixed\n", "integration fix", ticket_of="01")]}), *UNATTENDED)
312
+ assert rig.code == 2 and not rig.final_calls("final-spec") and rig.pushes() == [], rig.out
313
+ assert rig.led("End of run: BLOCKED at the integration gate: the full integration gate remains red")
314
+ assert stage(rig)["status"] == "awaiting-review" and stage(rig)["open_questions"] == 1
315
+ assert rig.state()["run"]["gates"] == {"fast": 1, "full": 2}
316
+ assert rig.final()["gate_repairs"] == 1
317
317
 
318
318
 
319
319
  # ---------------------------------------------------------------- the rebase
@@ -337,7 +337,7 @@ def test_a_base_that_moved_with_no_conflict_is_rebased_onto_with_no_agent_and_on
337
337
  assert rig.pushes() == [f"refs/heads/feat/csv {rig.branch()}"] and stage(rig) == {"stage": "implement", "status": "done"}
338
338
 
339
339
 
340
- def test_a_resolved_rebase_keeps_the_ticket_messages_and_gates_the_rebased_tip_and_the_tidied_tip(tmp_path):
340
+ def test_a_resolved_rebase_keeps_ticket_messages_and_gates_only_the_final_tidied_tip(tmp_path):
341
341
  cli = {"demo/cli.py": "def main():\n return 'base'\n"}
342
342
  resolved = {**RESOLVE, "files": {"demo/cli.py": "def main():\n return 'both'\n"}}
343
343
  rig = moved(tmp_path, cli, resolved) # the agent commits as "resolve conflict" and goes on with the rebase
@@ -351,7 +351,7 @@ def test_a_resolved_rebase_keeps_the_ticket_messages_and_gates_the_rebased_tip_a
351
351
  (line,) = rig.led("Rebase: the conflict agent resolved the conflict with main in demo/cli.py at ")
352
352
  rebased = line.rstrip(".").split()[-1]
353
353
  records = sorted(p.name for p in (rig.repo / ".agent/implement/final").glob("gate-*.log"))
354
- assert records == sorted([f"gate-full-{rebased}.log", f"gate-full-{rig.branch()[:7]}.log"]) and rebased != rig.branch()[:7]
354
+ assert records == [f"gate-full-{rig.branch()[:7]}.log"] and rebased != rig.branch()[:7]
355
355
  assert ref(rig.repo, f"{rebased}^{{tree}}") == ref(rig.repo, "feat/csv^{tree}")
356
356
 
357
357
 
@@ -385,12 +385,13 @@ def test_a_conflict_agent_that_gives_up_leaves_no_rebase_open(tmp_path):
385
385
  assert not (rig.repo / ".git/rebase-merge").exists()
386
386
 
387
387
 
388
- def test_a_red_gate_after_the_rebase_leaves_the_branch_unrewritten(tmp_path):
389
- rig = Inside(tmp_path, ONE, gate={"unbranched": True}) # red on a commit that no branch holds: the rebased tip
388
+ def test_rebase_conflict_resolution_waits_for_the_final_integration_gate(tmp_path):
389
+ rig = Inside(tmp_path, ONE, gate={"unbranched": True})
390
390
  rig.move_base({"demo/export.py": "def export_csv():\n return 'base'\n"})
391
391
  rig.run(plan(**{"final/conflict": [{**RESOLVE, "files": {"demo/export.py": "x = 1\n"}}]}))
392
- assert rig.code == 1 and rig.branch() == rig.recovery(), rig.out
393
- assert rig.led("End of run: BLOCKED at the rewrite: the gate after the rebase: the full gate is red on ")
392
+ assert rig.code == 0 and rig.branch() != rig.recovery(), rig.out
393
+ assert len(rig.gates("full")) == 1
394
+ assert rig.gates("full")[0]["commit"] == rig.branch()
394
395
 
395
396
 
396
397
  def test_a_base_that_holds_a_ticket_commit_already_leaves_the_branch_unrewritten(tmp_path):
@@ -331,24 +331,23 @@ def test_a_fast_forward_merge_has_one_fast_and_one_full_record_of_the_ticket_tip
331
331
  a1 = rig.sha("01", "implementer")
332
332
  assert rig.walked() == a1
333
333
  records = sorted((rig.repo / ".agent/implement/01").glob("gate-*.log"))
334
- assert [p.name for p in records] == [f"gate-fast-{a1[:7]}.log", f"gate-full-{a1[:7]}.log"]
335
- for tier, record in zip(("fast", "full"), records):
334
+ assert [p.name for p in records] == [f"gate-fast-{a1[:7]}.log"]
335
+ for tier, record in zip(("fast",), records):
336
336
  text = record.read_text()
337
337
  assert f"tier: {tier}\ncommit: {a1}\n" in text and "GATE-OUTPUT-MARK" in text
338
338
  assert len(re.findall(r"\d\d:\d\d:\d\d", text)) >= 2
339
339
  assert re.search(r"exit\D*0", text) and not re.search(r"^(\?\?| M|M |A )", text, re.M)
340
- fast, full = rig.walk_gates()
340
+ (fast,) = rig.walk_gates()
341
341
  assert (fast["tier"], fast["commit"], fast["branch"]) == ("fast", a1, "ticket/feat%2Fcsv/01")
342
- assert (full["tier"], full["commit"], full["branch"]) == ("full", a1, "HEAD") # the commit that lands, detached
343
- assert {gate["status"] for gate in (fast, full)} == {""}
344
- assert {gate["cwd"] for gate in (fast, full)} == {str(rig.repo.resolve())}
342
+ assert {gate["status"] for gate in (fast,)} == {""}
343
+ assert {gate["cwd"] for gate in (fast,)} == {str(rig.repo.resolve())}
345
344
 
346
345
 
347
346
  def test_gate_environment_names_the_pr_branch_and_a_pycache_prefix_under_agent_implement(tmp_path):
348
347
  rig = Rig(tmp_path, {"01-export-rows.md": ticket("01", "Export rows")}).run(plan())
349
348
  assert rig.code == 0, rig.output()
350
349
  gates = rig.walk_gates()
351
- assert [gate["tier"] for gate in gates] == ["fast", "full"]
350
+ assert [gate["tier"] for gate in gates] == ["fast"]
352
351
  for gate in gates:
353
352
  assert gate["base"] == "feat/csv" and gate["pycache"]
354
353
  assert os.path.realpath(gate["pycache"]).startswith(str((rig.repo / ".agent/implement").resolve()) + os.sep)
@@ -375,7 +374,7 @@ def test_blocked_ticket_stops_only_the_tickets_it_blocks(blocked):
375
374
  assert blocked.code == 1
376
375
 
377
376
 
378
- def test_non_fast_forward_merge_is_a_plumbing_merge_commit_gated_once(tmp_path):
377
+ def test_non_fast_forward_merge_is_a_plumbing_merge_commit_without_a_landing_gate(tmp_path):
379
378
  files = {k: v for k, v in three().items() if not k.startswith("02")}
380
379
  rig = Rig(tmp_path, files)
381
380
  steps = plan(**{"01_test-writer": [{**tw("01"), "touch": ["s1"]}],
@@ -388,8 +387,8 @@ def test_non_fast_forward_merge_is_a_plumbing_merge_commit_gated_once(tmp_path):
388
387
  assert len(git(rig.repo, "rev-list", "--parents", "-n1", tip).split()) == 3, "tip is a merge commit"
389
388
  fast = [g["commit"] for g in rig.walk_gates() if g["tier"] == "fast"]
390
389
  full = [g["commit"] for g in rig.walk_gates() if g["tier"] == "full"]
391
- # 03 lands first, as a fast-forward; 01 lands as the merge commit. No full gate runs on 01's own tip.
392
- assert sorted(fast) == sorted([a01, a03]) and full == [a03, tip], (fast, full)
390
+ # 03 lands first, as a fast-forward; 01 lands as the merge commit. Both wait for the final full gate.
391
+ assert sorted(fast) == sorted([a01, a03]) and full == [], (fast, full)
393
392
  waited = rig.calls("01", "implementer")[0]
394
393
  assert waited["after_wait"]["branch"] == "ticket/feat%2Fcsv/01" and waited["after_wait"]["head"] == waited["head"]
395
394
  assert waited["after_wait"]["status"] == ""
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "schemaVersion": 1,
3
- "generatedAt": "2026-11-09T11:10:12.678Z",
3
+ "generatedAt": "2026-11-09T16:01:06.702Z",
4
4
  "skills": [
5
5
  {
6
6
  "name": "agents-wayfinder",
@@ -58,8 +58,8 @@
58
58
  },
59
59
  {
60
60
  "name": "implement-spec",
61
- "version": "0.1.56",
62
- "hash": "sha256-1f894f578c7ffea9d1de8b0994c94e3d5499612e67ea2b7267f50d14b8162fda",
61
+ "version": "0.1.57",
62
+ "hash": "sha256-d5e79de9c7bbe2b41814bed8ae876a4731ea8acc5c1b84bba177572b17a76dc9",
63
63
  "description": "Implement a specification in code."
64
64
  },
65
65
  {