cap_wall

LimitSeen in: The editor, Charts, RunsSee the limit

What happened

A script runs with a limit on the elapsed time it may use. When it goes over, the sandbox stops it and answers with this code. detail names the cap that tripped (wall_ms), how much the script used and how much was allowed. The caps differ for a chart and for a run, and the code sandbox section of the Limits page lists them.

What to do

Do less work per call, and check that the script does not wait on anything. Time spent waiting counts here even when the CPU is idle.

Example

json
{
  "request_id": "7d2b1c44-95a0-4e3b-8a6f-1c0d9e2f5a37",
  "ok": false,
  "error": {
    "code": "cap_wall",
    "message": "The script ran longer than allowed.",
    "detail": {
      "cap": "wall_ms",
      "used": 5400,
      "allowed": 5000
    }
  }
}

Ask about this in the forum