• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

kobotoolbox / kpi / 29898097149
82%
master: 76%

Build:
Build:
LAST BUILD BRANCH: dev-2427-persist-last-id-in-root-uuid-lrm
DEFAULT BRANCH: master
Ran 22 Jul 2026 06:55AM UTC
Jobs 10
Files 896
Run time 2min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

22 Jul 2026 06:50AM UTC coverage: 81.831% (+0.001%) from 81.83%
29898097149

push

github

web-flow
fix(openapi): type validation error responses as ErrorValidation DEV-1220 (#7275)

### đŸ“Ŗ Summary

The API reference now documents validation errors with their real shape
— a map of field name to error messages — instead of an untyped
placeholder.

### 📖 Description

When a request fails validation, the KoboToolbox API returns each
field's errors as a list of messages. Until now the API reference
described this `400` response as an untyped `detail` object, which
didn't match what the API actually sends. It is now documented
accurately, so anyone building against the API — or relying on the types
generated from its schema — gets the correct shape for validation
errors.

### 💭 Notes

- Renamed the OpenAPI type `ErrorObject` (`{ detail: unknown }`) →
`ErrorValidation` (`Record<string, string[]>`), matching DRF's unwrapped
serializer `ValidationError` payloads (there is no `detail` envelope —
the custom exception handler delegates to stock DRF). A new
`ErrorValidationSerializer` plus a drf-spectacular
`OpenApiSerializerExtension` emit `additionalProperties: string[]`; the
`400` example was flattened to match.
- Regenerated `static/openapi/*` and the orval client. `ServerError` no
longer `implements` the renamed type and the `orval.types.d.ts` `Error`
augmentation for it was dropped — a validation map isn't an `Error`.
- The two list views (`MembersRoute`, `usageProjectBreakdown`) now type
their table error as `ErrorDetail` (their GET hooks never return a
validation map); also fixed a stray `schema-utils` `ErrorObject` import
in `UniversalTable`.
- No runtime behavior change. Gates green: tsc, biome, ruff, darker,
schema generation (no drf-spectacular warnings).

### 👀 Preview steps

1. â„šī¸ open the API docs at `/api/v2/docs/` on an endpoint that can
return `400` (e.g. create asset)
2. look at the documented `400 Bad Request` response body and its
example
3. 🔴 [on main] the schema is `ErrorObject` = `{ detail: <unknown> }` and
the example wraps the errors un... (continued)

9464 of 12768 branches covered (74.12%)

8 of 9 new or added lines in 3 files covered. (88.89%)

30671 of 37481 relevant lines covered (81.83%)

5.52 hits per line

Uncovered Changes

Lines Coverage ∆ File
1
85.71
kpi/schema_extensions/v2/generic/extensions.py
Jobs
ID Job ID Ran Files Coverage
1 29898097149.1 22 Jul 2026 06:55AM UTC 892
44.29
2 29898097149.2 22 Jul 2026 06:56AM UTC 892
52.87
3 29898097149.3 22 Jul 2026 06:56AM UTC 892
49.42
4 29898097149.4 22 Jul 2026 06:56AM UTC 894
45.65
5 29898097149.5 22 Jul 2026 06:57AM UTC 894
50.74
6 29898097149.6 22 Jul 2026 06:57AM UTC 894
54.12
7 29898097149.7 22 Jul 2026 06:58AM UTC 894
67.11
8 29898097149.8 22 Jul 2026 06:58AM UTC 892
59.07
9 29898097149.9 22 Jul 2026 07:00AM UTC 894
60.21
10 29898097149.10 22 Jul 2026 07:01AM UTC 896
69.37
Source Files on build 29898097149
  • Tree
  • List 896
  • Changed 2
  • Source Changed 0
  • Coverage Changed 2
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • 31329495 on github
  • Prev Build on main (#29853932907)
  • Next Build on main (#29915646745)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc