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

kobotoolbox / kpi / 29431514116
81%
master: 76%

Build:
Build:
LAST BUILD BRANCH: dev-2450-lrm-0027-do-not-flag-xform-as-failed-when-celery-times-out
DEFAULT BRANCH: master
Ran 15 Jul 2026 04:19PM UTC
Jobs 10
Files 894
Run time 3min
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

15 Jul 2026 04:13PM UTC coverage: 81.389% (+0.007%) from 81.382%
29431514116

push

github

web-flow
feat(search): switch relational-lookup validation from blacklist to allowlist for q search DEV-2417 (#7243)

### πŸ“£ Summary
Implemented the allowlist approach for the q search endpoint to replace
the old blacklist method plus super users bypass the allowlist

### πŸ“– Description
Changes included in this PR:
* Added `ALLOWED_LOOKUP_FIELDS` and `DENIED_LOOKUP_FIELDS` to
`kpi/constants.py` mapping out which explicitly allowed fields are
available per model (used Gemini to find this list and included the
prompt used)
* Updated `QueryParseActions._validate_field` inside
`kpi/utils/query_parser/query_parser.py` to stop using the previous
blacklist and solely rely on the new allowlist mapping
* Kept the native JSONField validation and Django transform parsing,
meaning validation stops appropriately at a JSONField (leaving nested
keys unprocessed for relation logic) and implicit lookup filters like
`__icontains` bypass relationship checks
* Extended the `parse()` method to accept a `user` argument and updated
`kpi/filters.py` to pass `request.user` downstream to allow superusers
to bypass the allowlist checks

### πŸ‘€ Preview steps
Covered in unit tests, no need to test blocked queries

---------

Co-authored-by: Olivier LΓ©ger <olivierleger@gmail.com>

9272 of 12616 branches covered (73.49%)

22 of 22 new or added lines in 4 files covered. (100.0%)

649 existing lines in 26 files now uncovered.

30249 of 37166 relevant lines covered (81.39%)

5.52 hits per line

Coverage Regressions

Lines Coverage βˆ† File
139
37.13
-45.28% kpi/views/v2/data.py
97
61.89
-26.22% kpi/views/v2/asset.py
63
34.55
-57.27% kpi/views/v2/paired_data.py
53
42.86
-50.48% kpi/views/v2/environment.py
42
49.47
-44.21% kpi/views/v2/asset_permission_assignment.py
41
43.7
-30.37% kpi/views/v2/asset_snapshot.py
32
50.75
-47.76% kpi/views/v2/asset_export_settings.py
27
83.0
-13.5% kpi/utils/xml.py
24
59.32
-40.68% kpi/views/v2/export_task.py
19
51.06
-40.43% kpi/views/v2/import_task.py
19
49.25
-28.36% kpi/views/v2/user.py
18
48.65
-48.65% kpi/views/v2/attachment_audio_duration.py
16
62.9
-25.81% kpi/views/v2/attachment.py
10
63.33
-33.33% kpi/views/v2/asset_version.py
9
79.17
-18.75% kpi/views/v2/asset_file.py
7
74.07
-25.93% kpi/views/v2/attachment_delete.py
7
75.86
-24.14% kpi/views/v2/tag.py
5
76.0
-20.0% kpi/views/v2/asset_submission_counts.py
5
61.54
-38.46% kpi/views/v2/logout.py
5
73.91
-21.74% kpi/views/v2/user_asset_subscription.py
3
75.0
-25.0% kpi/views/v2/open_rosa.py
3
84.21
-15.79% kpi/views/v2/permission.py
2
88.24
-11.76% kpi/views/v2/service_usage.py
1
84.62
-7.69% kpi/versioning.py
1
55.56
-2.22% kpi/views/current_user.py
1
93.33
-6.67% kpi/views/v2/asset_usage.py
Jobs
ID Job ID Ran Files Coverage
1 29431514116.1 15 Jul 2026 04:19PM UTC 890
44.42
2 29431514116.2 15 Jul 2026 04:20PM UTC 890
52.95
3 29431514116.3 15 Jul 2026 04:20PM UTC 892
45.79
4 29431514116.4 15 Jul 2026 04:20PM UTC 890
49.59
5 29431514116.5 15 Jul 2026 04:20PM UTC 892
54.21
6 29431514116.6 15 Jul 2026 04:21PM UTC 892
50.93
7 29431514116.7 15 Jul 2026 04:22PM UTC 890
58.97
8 29431514116.8 15 Jul 2026 04:22PM UTC 892
66.64
9 29431514116.9 15 Jul 2026 04:23PM UTC 894
68.95
10 29431514116.10 15 Jul 2026 04:23PM UTC 892
60.13
Source Files on build 29431514116
  • Tree
  • List 894
  • Changed 4
  • Source Changed 0
  • Coverage Changed 4
Coverage βˆ† File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • 9efbb9aa on github
  • Prev Build on release/2.026.27 (#29029441589)
  • Next Build on release/2.026.27 (#29435767219)
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