Arcp::Lease::LeaseConstraints carries max_budget, and the README shows it as part of submit_job, but the runtime never applies it. lib/arcp/lease.rb:11 defines the field and lib/arcp/lease.rb:21 through lib/arcp/lease.rb:23 serializes it, yet lib/arcp/runtime/job_manager.rb:221 through lib/arcp/runtime/job_manager.rb:227 builds the accepted lease directly from submit.lease_request.budget and only considers lease_constraints.expires_at. A client can therefore request a lease budget above the declared maximum and receive it unchanged.
Fix prompt: Define the expected max_budget wire shape and enforce it in lease construction before the job is accepted. The runtime should reject or clamp a lease request whose per-currency budget exceeds the constraint, and rejection should surface as Arcp::Errors::InvalidRequest or Arcp::Errors::LeaseSubsetViolation consistently with the protocol. Add request/response round-trip tests for LeaseConstraints#max_budget and an integration spec proving an over-budget submit_job does not start an agent task.
Arcp::Lease::LeaseConstraintscarriesmax_budget, and the README shows it as part ofsubmit_job, but the runtime never applies it.lib/arcp/lease.rb:11defines the field andlib/arcp/lease.rb:21throughlib/arcp/lease.rb:23serializes it, yetlib/arcp/runtime/job_manager.rb:221throughlib/arcp/runtime/job_manager.rb:227builds the accepted lease directly fromsubmit.lease_request.budgetand only considerslease_constraints.expires_at. A client can therefore request a lease budget above the declared maximum and receive it unchanged.Fix prompt: Define the expected
max_budgetwire shape and enforce it in lease construction before the job is accepted. The runtime should reject or clamp a lease request whose per-currency budget exceeds the constraint, and rejection should surface asArcp::Errors::InvalidRequestorArcp::Errors::LeaseSubsetViolationconsistently with the protocol. Add request/response round-trip tests forLeaseConstraints#max_budgetand an integration spec proving an over-budgetsubmit_jobdoes not start an agent task.