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

Freegle / Iznik / 5677
70%

Build:
DEFAULT BRANCH: master
Ran 23 Apr 2026 07:57PM UTC
Jobs 4
Files 989
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

23 Apr 2026 06:40PM UTC coverage: 71.571% (-0.03%) from 71.599%
5677

push

circleci

web-flow
perf(modtools): UNION ALL per groupid for /modtools/messages (~5000x faster) (#242)

* perf(modtools): speed up /modtools/messages listing via UNION ALL per groupid

`ListMessagesMT` issued one query with `WHERE mg.groupid IN (list)`.  MySQL
falls back to a temporary-table + filesort because the composite
messages_groups(groupid, collection, deleted, arrival) index is ordered per
groupid, not globally — so for a mod of four large groups the query took
~26.7s on prod.

Rewrite each branch (default, searchall, searchmemb) as a UNION ALL over
one subquery per groupid, each with its own backward index scan and LIMIT.
Prod timing drops to ~5–8ms (roughly 5,000x faster).  `SELECT DISTINCT` is
kept only in the users_emails LEFT JOIN branch where duplication is real;
elsewhere (msgid, groupid) uniqueness in messages_groups makes DISTINCT
redundant now that each branch is keyed to one groupid.

Regression test covers a mod with 2 active groups and interleaved arrival
times: first page must be globally DESC-ordered (not grouped by groupid),
and the pagination cursor must yield the remaining messages in order.

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>

* fix(modtools): deduplicate cross-group messages in UNION ALL listing

A message posted to multiple groups appeared once per UNION branch,
breaking TestListMessagesMTMultiGroupNoDuplicates.  Wrap the UNION ALL in
GROUP BY msgid with MAX(arrival) so cross-posted messages collapse to one
row ordered by their most-recent arrival across all queried groups.

This preserves the original SELECT DISTINCT semantics while keeping the
index-seek + early-termination benefit of the per-group UNION ALL plan.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Haiku 4.5 <noreply@anthropic.com>

13371 of 20348 branches covered (65.71%)

Branch coverage included in aggregate %.

32 of 73 new or added lines in 1 file covered. (43.84%)

36 existing lines in 6 files now uncovered.

96295 of 132878 relevant lines covered (72.47%)

21.41 hits per line

Uncovered Changes

Lines Coverage ∆ File
41
75.93
4.58% iznik-server-go/message/message_list.go

Coverage Regressions

Lines Coverage ∆ File
21
70.06
-14.94% iznik-nuxt3/layouts/default.vue
6
30.82
-3.42% iznik-nuxt3/pages/browse/[[term]].vue
4
48.08
-37.89% iznik-nuxt3/pages/index.vue
2
58.33
-12.25% iznik-nuxt3/app.vue
2
75.93
4.58% iznik-server-go/message/message_list.go
1
82.17
-0.32% iznik-nuxt3/components/LoginModal.vue
Jobs
ID Job ID Ran Files Coverage
5677 playwright - 5677 23 Apr 2026 07:57PM UTC 228
45.33
CircleCI Job 5677
5677 go - 5677 23 Apr 2026 07:57PM UTC 118
80.61
CircleCI Job 5677
5677 laravel - 5677 23 Apr 2026 07:57PM UTC 180
66.67
CircleCI Job 5677
5677 vitest - 5677 23 Apr 2026 07:57PM UTC 686
64.59
CircleCI Job 5677
Source Files on build 5677
  • Tree
  • List 989
  • Changed 15
  • Source Changed 0
  • Coverage Changed 15
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • CircleCI Build #5677
  • ba809f05 on github
  • Prev Build on master (#5651)
  • Next Build on master (#5738)
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