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

kobotoolbox / kpi / 27365497735 / 7
82%
master: 76%

Build:
Build:
LAST BUILD BRANCH: dependabot/github_actions/actions-deps-78e37b62cc
DEFAULT BRANCH: master
Ran 11 Jun 2026 05:40PM UTC
Files 881
Run time 1min
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: 51.536% (-17.3%) from 68.857%
27365497735.7

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)

4517 of 12132 branches covered (37.23%)

18694 of 36274 relevant lines covered (51.54%)

0.52 hits per line

Source Files on job 27365497735.7
  • Tree
  • List 881
  • Changed 315
  • Source Changed 0
  • Coverage Changed 315
Coverage βˆ† File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Build 27365497735
  • d50cfdad on github
  • Prev Job for on main (#27365258343.10)
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