schemathesis "hypothesis DeadlineExceeded" in CI
schemathesis runs on top of Hypothesis, which fails an example that exceeds a per-test deadline (200ms by default). A slow endpoint or a cold CI runner can trip this even when the response is correct.
What this error means
schemathesis reports a failure with "hypothesis.errors.DeadlineExceeded: Test took T ms, which exceeds the deadline of 200.00ms" for an otherwise valid endpoint.
hypothesis.errors.DeadlineExceeded: Test took 512.44ms, which exceeds
the deadline of 200.00msCommon causes
The endpoint is genuinely slow in CI
A cold runner, an unwarmed cache, or a heavy handler makes a single request exceed the 200ms Hypothesis deadline even though it succeeds.
The default deadline is too tight for integration tests
Hypothesis deadlines suit fast unit properties; real HTTP round-trips in CI often exceed 200ms without any real problem.
How to fix it
Raise or disable the Hypothesis deadline
Pass a larger deadline (or none) for HTTP integration runs so a slow-but-correct response does not fail.
schemathesis run http://localhost:8000/openapi.json \
--hypothesis-deadline=NoneWarm the service before the run
Send a warm-up request so the first generated example does not pay cold-start latency.
curl -s http://localhost:8000/health >/dev/null
schemathesis run http://localhost:8000/openapi.jsonHow to prevent it
- Set a realistic Hypothesis deadline for HTTP integration runs.
- Warm the API before schemathesis starts generating.
- Separate slow endpoints so one does not fail the whole suite on latency.