HIL contract: describe task-scoped board locks (agentrc#464) and bump agentrc

Open
#613 1 comment 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
67/100
Issue type
Documentation
Clarity
Clearly specified
Activity status
Active
Tech stack
arduino, c
Domain
testing

Research direction

Read .claude/skills/hil-contract/SKILL.md at the Recovery, Verdicts, and Execution sections, then check the staged agentrc changes and evidence described in the issue. Update the contract for task-scoped locks, cleanup failure reporting, dev_attached restore failures, and manual session exit codes; bump test/hil/agentrc.json to the merged agentrc commit. Done when the documented behavior and pinned commit match.

Written by the indexing model from the issue text.

Description

follow-up

Follow-up from hathach/agentrc#474 (fixes hathach/agentrc#464): agentrc's board locks become task scoped. The shared
Arduino engine (arduino_hil.py) already releases a board whose cleanup failed, logs it in the board's cleanup log
and reports the earlier failure on the next run (previousCleanupFailure); this library's contract still describes
the old recovery. The library keeps working on its current pin.

Remaining work

  • .claude/skills/hil-contract/SKILL.md Recovery (:281 "Take the board for the restore, keeping it blocked
    throughout") and Verdicts: a failed restore no longer holds the board; no takeover or release --token for our own
    runs. A run reports previousCleanupFailure / openCleanupFailures and previousPending (an older engine's
    pending record, never a refusal).
  • dev_attached boards (Pico 2's 0951:1603 stick, #600): a missing attached device fails the restore, which is now
    logged and reported each run rather than blocking the board; say so in the contract.
  • Manual sessions: restore --release now releases whatever the restore did (exit 0 restored, 6 restore failed and
    released, 5 not released) and session close counts 6 as closed; document the codes in Execution.
  • Bump test/hil/agentrc.json to the merged agentrc commit in the same PR.

Evidence

ci.lan, this library at b01c38d with agentrc#474 staged, raspberry_pi_pico2: runs v464-r1 and v464-r2 both
ran host_device_info, failed it and the restore (/dev/ttyACM19: reported [], missing [('0951:1603', '820000000000000045B46338')]), ended released: true with verdict blocker; r2 reported r1's failure
3bd6522a9787cb4b; hil_lock.py status showed no holder.

Deferred because it is this library's contract, pinned separately.

Dominant language
C
Stars
654
Forks
187
Avg merge
21h 1m
Merged PRs (30d)
17

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from adafruit/Adafruit_TinyUSB_Arduino

All issues in adafruit/Adafruit_TinyUSB_Arduino

Similar issues

More C issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.