Problem
--wait polling assumes every Location header is a relative path. Many APIs return an absolute URL in Location, which currently gets concatenated with the selected hostname and produces an invalid request URL.
Evidence
pkg/runtime/build.go passes the raw Location header from a 202 Accepted response into PollUntilDone.
pkg/runtime/poll.go calls DoRawFull(ctx, hostname, "GET", location, ...) on each poll attempt.
pkg/runtime/client.go builds the request URL as base + path, so an absolute Location like https://api.example.com/jobs/1 becomes https://api.example.comhttps://api.example.com/jobs/1.
- Existing poll tests only cover relative
Location: /status.
Expected behavior
Polling should accept relative locations and same-host absolute URLs. Cross-host absolute URLs should either be rejected clearly or handled only under an explicit policy, so polling does not silently produce invalid URLs or unexpected outbound requests.
Verification
make test currently passes; current coverage does not include absolute Location headers.
Problem
--waitpolling assumes everyLocationheader is a relative path. Many APIs return an absolute URL inLocation, which currently gets concatenated with the selected hostname and produces an invalid request URL.Evidence
pkg/runtime/build.gopasses the rawLocationheader from a202 Acceptedresponse intoPollUntilDone.pkg/runtime/poll.gocallsDoRawFull(ctx, hostname, "GET", location, ...)on each poll attempt.pkg/runtime/client.gobuilds the request URL asbase + path, so an absoluteLocationlikehttps://api.example.com/jobs/1becomeshttps://api.example.comhttps://api.example.com/jobs/1.Location: /status.Expected behavior
Polling should accept relative locations and same-host absolute URLs. Cross-host absolute URLs should either be rejected clearly or handled only under an explicit policy, so polling does not silently produce invalid URLs or unexpected outbound requests.
Verification
make testcurrently passes; current coverage does not include absoluteLocationheaders.