1.5 KiB
Prompt
After committing explicit WireGuard peer configuration, the human authorized the next incremental lifecycle change.
Response summary
Added owned WireGuard interface provisioning and teardown through cancellation-shielded pyroute2 worker calls. Role-specific policy is validated before mutation, local addresses and explicit peers are configured, and owned interfaces are removed on exit. Staged review clarified role-specific test assertions, added the second peer’s endpoint-port check, included conflicting values in policy errors and aligned annotated assignment with /py-codestyle.
Files changed
tractor/discovery/_tunnel.py- role policy and WG iface lifecycle.tractor/discovery/__init__.py- public lifecycle and role exports.tests/discovery/test_wg_iface_lifecycle.py- policy and cancellation coverage with privileged calls faked.ai/tpt-backends/03_wg_tunnel_bindspace.md- initial owned WG iface lifecycle contract.
Human edits
The human selected continuation from explicit peer modeling into the owned WireGuard interface lifecycle. During staged review, the human requested clearer role assertions, complete endpoint checks, concrete error values and inline annotated assignment. The agent applied those human-directed edits; no direct manual source edits were observed.