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

kobotoolbox / kpi / 27365497735
82%
master: 76%

Build:
Build:
LAST BUILD BRANCH: dependabot/github_actions/actions-deps-78e37b62cc
DEFAULT BRANCH: master
Ran 11 Jun 2026 05:36PM UTC
Jobs 10
Files 883
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

11 Jun 2026 05:32PM UTC coverage: 81.594% (+0.005%) from 81.589%
27365497735

push

github

web-flow
refactor(formMedia): orvalify component DEV-2176 (#7135)

### πŸ’­ Notes

Migrated FormMedia component from legacy Reflux actions to React Query
with orval-generated API endpoints.

Changes here:

**Backend - OpenAPI Schema:** (AI assisted)
- `kpi/views/v2/asset_file.py` - Added missing `file_type` query
parameter to the files list endpoint docs (backend already supported it,
just wasn't in the schema)
- `kpi/schema_extensions/v2/files/serializers.py` - Refactored
CreateFilePayload to use PolymorphicProxySerializer for cleaner union
types
- `static/openapi/schema_v2.{yaml,json}` - Regenerated schemas with the
file_type parameter

**Frontend - Component Migration:**
- `jsapp/js/project/FormMedia/index.tsx` - Replaced Reflux actions
(`actions.media.*`) with React Query hooks (`useAssetsFilesList`,
`useAssetsFilesCreate`, `useAssetsFilesDestroy`)
- Now uses `useIsMutating` with a custom mutation key to track
concurrent file uploads separately from URL uploads (since drag-and-drop
can upload multiple files at once)
- Ditched the custom `usePendingUploads` hook in favor of React Query's
state
  - Field-level error handling now works inline
  
**Frontend - Type Safety:**
- `jsapp/js/api/mutation-defaults/survey-data.ts` - Global mutation
defaults for cache invalidation
- `jsapp/js/endpoints/formMedia.mocks.ts` - Updated MSW handlers to
match orval types

**Testing:**
- `jsapp/js/project/FormMedia/FormMedia.stories.tsx` - Stories pass with
updated mocks

No reflux bridge routes needed since all `actions.media.*` consumers
were already migrated.

### πŸ‘€ Preview steps

1. Have a deployed project with a form
2. Go to **Project β†’ Form β†’ Media**
3. **File uploads:**
   - Drag 2-3 files into the dropzone at once
   - Should show "Uploading file…" while they're going up
   - Files show up in the list when done (no refresh)
4. **URL uploads:**
   - Paste a URL (like `https://example.com/image.png`) into the input
   - Click "Add"
   - Should appear in the list with a li... (continued)

9035 of 12268 branches covered (73.65%)

20 of 29 new or added lines in 4 files covered. (68.97%)

2 existing lines in 1 file now uncovered.

29665 of 36357 relevant lines covered (81.59%)

5.56 hits per line

Uncovered Changes

Lines Coverage βˆ† File
8
57.62
-0.8% kpi/filters.py
1
79.17
4.17% kpi/views/v2/asset_file.py

Coverage Regressions

Lines Coverage βˆ† File
2
57.62
-0.8% kpi/filters.py
Jobs
ID Job ID Ran Files Coverage
1 27365497735.1 11 Jun 2026 05:36PM UTC 879
50.17
2 27365497735.2 11 Jun 2026 05:37PM UTC 879
44.89
3 27365497735.3 11 Jun 2026 05:37PM UTC 879
53.54
4 27365497735.4 11 Jun 2026 05:38PM UTC 881
54.84
5 27365497735.5 11 Jun 2026 05:38PM UTC 881
46.29
6 27365497735.6 11 Jun 2026 05:39PM UTC 881
66.51
7 27365497735.7 11 Jun 2026 05:40PM UTC 881
51.54
8 27365497735.8 11 Jun 2026 05:40PM UTC 879
59.45
9 27365497735.9 11 Jun 2026 05:40PM UTC 881
60.63
10 27365497735.10 11 Jun 2026 05:41PM UTC 883
68.87
Source Files on build 27365497735
  • Tree
  • List 883
  • Changed 4
  • Source Changed 0
  • Coverage Changed 4
Coverage βˆ† File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • d50cfdad on github
  • Prev Build on main (#27365258343)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc