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

kobotoolbox / kpi / 14834536167 / 2
81%
master: 76%

Build:
Build:
LAST BUILD BRANCH: beccagraber/dev-1453-run-external-process
DEFAULT BRANCH: master
Ran 05 May 2025 12:00PM UTC
Files 654
Run time 15s
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

05 May 2025 10:39AM UTC coverage: 80.816% (+2.1%) from 78.691%
14834536167.2

push

github

web-flow
feat(attachments): update storage counters when attachments are moved to or from trash TASK-590 (#5686)

### 📣 Summary
Ensure storage counters are updated when attachments are trashed or
restored in ongoing projects.


### 📖 Description
This change improves storage accounting by updating
`attachment_storage_bytes` on both `UserProfile` and `XForm` when
attachments are soft-deleted or restored using
`AttachmentTrash.toggle_statuses()`.
- When an attachment is moved to the trash,
`pre_delete_attachment(only_update_counters=True)` is invoked to
decrement storage usage.
- When an attachment is restored, `post_save_attachment(created=True)`
is used to restore the counters.
- Logic is in place to prevent counters from being decremented twice if
the submission is deleted after the attachment has already been trashed.

---------

Co-authored-by: Olivier Leger <olivierleger@gmail.com>

6240 of 9916 branches covered (62.93%)

23658 of 29274 relevant lines covered (80.82%)

0.81 hits per line

Source Files on job 14834536167.2
  • Tree
  • List 654
  • Changed 20
  • Source Changed 0
  • Coverage Changed 20
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Build 14834536167
  • fadfc21f on github
  • Prev Job for on main (#14796463193.1)
  • Next Job for on main (#14863645648.1)
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