Files
bitcoin/test/functional/interface_rest.py
w0xlt 862a179556 http: add no-store to dispatcher-generated error responses
REST error responses normally go through RESTERR(), which sets
Cache-Control: no-store. Some errors are returned directly by the
generic HTTP dispatcher and bypass RESTERR(), including unmatched
paths, queue exhaustion, handler exceptions, and shutdown rejection.

Use a shared reply helper to set no-store on dispatcher-generated
error responses. This avoids caching transient errors and keeps the
behavior consistent across REST and RPC requests.

Test the work-queue rejection path by checking that its HTTP 503
response includes the header.
2026-08-05 16:38:06 -07:00

34 KiB
Executable File