clarify-l1-signing-bytes: Clarify L1 signing byte layout #3

Open
std-bot wants to merge 1 commit from task/clarify-l1-signing-bytes into main
First-time contributor

Assigned idea

Benchmark authoring specification.

Summary: Create a deterministic docs-only upstream change that expands the L1 action signing section with exact byte-layout requirements for nonce, vault, expiresAfter, connectionId, and EIP-712 domain/message fields.

Task intent: Improve the upstream signing documentation so custom integrations can implement L1 action signing without ambiguity, especially around byte concatenation order and optional vault/expiresAfter markers.

Benchmark plan: Construct a regular task package that asks the solver to edit only docs/signing.md. The prompt should describe the desired upstream documentation improvement, not mention any benchmark or harness context. Include the current docs/signing.md as repository context and require a concise Markdown addition under the L1 action section that preserves the documented signing flow while making byte encodings explicit.

Environment plan: The task environment is the checked-out nktkas/hyperliquid repository at commit 52c032d3c5cb63190ca853ea07c4dd4031895657. No network services or Hyperliquid credentials are required. The verifier environment only needs Python 3 to inspect docs/signing.md; it should not depend on external package installation. The repository environment remains otherwise unchanged.

Verifier plan: Implement test_outputs.py to read docs/signing.md and assert that the L1 action section still contains the required ordered concepts: msgpack encoding, nonce as uint64 big-endian, vault marker 0x01 plus 20-byte address or 0x00, expiresAfter marker 0x00 plus uint64 big-endian timestamp, Keccak-256 connectionId, Exchange domain, chainId 1337, verifyingContract 0x0...0, Agent type, source, and connectionId. The test should also assert that the new text appears before the User-signed action section and does not remove the existing Signing heading.

Oracle plan: The oracle solution is a minimal Markdown patch to docs/signing.md adding a short byte-layout note or table beneath the existing L1 action flow. It should explicitly state the append order and byte widths for nonce, vault, and expiresAfter, and restate that the resulting Keccak-256 hash is signed as Agent.connectionId under the Exchange EIP-712 domain.

Difficulty plan: Coding agents may over-edit the documentation, conflate L1 actions with user-signed actions, omit big-endian or marker-byte details, or incorrectly claim the action object itself is signed. A verifier focused on concrete signing terms catches these common mistakes while keeping the task deterministic.

Repo patch scope: Expected upstream edits are limited to docs/signing.md only.

Anti-leakage notes: Solver-facing materials must not mention benchmark, harness, Snorkel, Harbor, std-ts, agent, stage, attempt, retry, generated task, or evaluation context. Phrase the request as an ordinary documentation improvement for maintainers and users.

Approach: Ask the solver to update the L1 action documentation with a precise byte-order explanation and preserve the current distinction between L1 actions and user-signed actions.

Verification: Run python3 test_outputs.py from the repository root; it must inspect docs/signing.md and pass all content and ordering assertions.

Risk: The main risk is making the documentation too prescriptive beyond the cited behavior. Keep the oracle tied to the existing documented flow and avoid adding unsupported examples or new API claims.

Path rules: task package is tasks/; mutable upstream checkout is tasks//environment/repo; benchmark package files are under tasks//task; verifier/container environment belongs under tasks//task/environment; regular and UI verifier logic belongs in task/tests/test_outputs.py and test.sh only runs that file through pytest.

Agent context

Task slug: clarify-l1-signing-bytes
Branch: task/clarify-l1-signing-bytes

## Assigned idea Benchmark authoring specification. Summary: Create a deterministic docs-only upstream change that expands the L1 action signing section with exact byte-layout requirements for nonce, vault, expiresAfter, connectionId, and EIP-712 domain/message fields. Task intent: Improve the upstream signing documentation so custom integrations can implement L1 action signing without ambiguity, especially around byte concatenation order and optional vault/expiresAfter markers. Benchmark plan: Construct a regular task package that asks the solver to edit only docs/signing.md. The prompt should describe the desired upstream documentation improvement, not mention any benchmark or harness context. Include the current docs/signing.md as repository context and require a concise Markdown addition under the L1 action section that preserves the documented signing flow while making byte encodings explicit. Environment plan: The task environment is the checked-out nktkas/hyperliquid repository at commit 52c032d3c5cb63190ca853ea07c4dd4031895657. No network services or Hyperliquid credentials are required. The verifier environment only needs Python 3 to inspect docs/signing.md; it should not depend on external package installation. The repository environment remains otherwise unchanged. Verifier plan: Implement test_outputs.py to read docs/signing.md and assert that the L1 action section still contains the required ordered concepts: msgpack encoding, nonce as uint64 big-endian, vault marker 0x01 plus 20-byte address or 0x00, expiresAfter marker 0x00 plus uint64 big-endian timestamp, Keccak-256 connectionId, Exchange domain, chainId 1337, verifyingContract 0x0...0, Agent type, source, and connectionId. The test should also assert that the new text appears before the User-signed action section and does not remove the existing Signing heading. Oracle plan: The oracle solution is a minimal Markdown patch to docs/signing.md adding a short byte-layout note or table beneath the existing L1 action flow. It should explicitly state the append order and byte widths for nonce, vault, and expiresAfter, and restate that the resulting Keccak-256 hash is signed as Agent.connectionId under the Exchange EIP-712 domain. Difficulty plan: Coding agents may over-edit the documentation, conflate L1 actions with user-signed actions, omit big-endian or marker-byte details, or incorrectly claim the action object itself is signed. A verifier focused on concrete signing terms catches these common mistakes while keeping the task deterministic. Repo patch scope: Expected upstream edits are limited to docs/signing.md only. Anti-leakage notes: Solver-facing materials must not mention benchmark, harness, Snorkel, Harbor, std-ts, agent, stage, attempt, retry, generated task, or evaluation context. Phrase the request as an ordinary documentation improvement for maintainers and users. Approach: Ask the solver to update the L1 action documentation with a precise byte-order explanation and preserve the current distinction between L1 actions and user-signed actions. Verification: Run python3 test_outputs.py from the repository root; it must inspect docs/signing.md and pass all content and ordering assertions. Risk: The main risk is making the documentation too prescriptive beyond the cited behavior. Keep the oracle tied to the existing documented flow and avoid adding unsupported examples or new API claims. Path rules: task package is tasks/<slug>; mutable upstream checkout is tasks/<slug>/environment/repo; benchmark package files are under tasks/<slug>/task; verifier/container environment belongs under tasks/<slug>/task/environment; regular and UI verifier logic belongs in task/tests/test_outputs.py and test.sh only runs that file through pytest. ## Agent context Task slug: clarify-l1-signing-bytes Branch: task/clarify-l1-signing-bytes <!-- std-ts:idea-pr-body -->
This pull request can be merged automatically.
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin task/clarify-l1-signing-bytes:task/clarify-l1-signing-bytes
git switch task/clarify-l1-signing-bytes

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch main
git merge --no-ff task/clarify-l1-signing-bytes
git switch task/clarify-l1-signing-bytes
git rebase main
git switch main
git merge --ff-only task/clarify-l1-signing-bytes
git switch task/clarify-l1-signing-bytes
git rebase main
git switch main
git merge --no-ff task/clarify-l1-signing-bytes
git switch main
git merge --squash task/clarify-l1-signing-bytes
git switch main
git merge --ff-only task/clarify-l1-signing-bytes
git switch main
git merge task/clarify-l1-signing-bytes
git push origin main
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
snorkel/root-repository-maintenance-e1fa0b0580dd4c!3
No description provided.