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

aio-libs / multidict / 37602367403
86%

Build:
DEFAULT BRANCH: master
Ran 07 Oct 2026 09:42AM UTC
Jobs 1
Files 49
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

07 Oct 2026 09:41AM UTC coverage: 85.961%. Remained the same
37602367403

push

github

web-flow
Fold _iter_scan into _iter_next_entry (#1732)

<!-- Thank you for your contribution! -->

## What do these changes do?

Folded `_iter_scan()` into `_iter_next_entry()` and dropped
`ALWAYS_INLINE` from the latter, which is plain `static inline` now. The
merged function checks the table kind first and the direction second,
with one loop per kind and direction, so each loop still steps by a
constant entry size. The `_iter_scan` rule in `tools/check_inlining.py`
went away with the helper; the `_iter_next_entry` rule stays and passes,
so GCC still inlines it into every `__next__`.

Cost (callgrind, Ir per op, CPython 3.14.7): GIL is flat or slightly
cheaper; FT `iter_keys` +3 Ir (+3.7%) and `iter_items` +4 Ir (+2.4%).
Keeping `ALWAYS_INLINE` on the merged function instead measured 0 to -1
Ir on every iterator row on both builds, if that trade is preferred.
Checking direction before kind cost about 2 Ir more even with
`ALWAYS_INLINE`, which is why the loops are ordered kind first.

## Are there changes in behavior for the user?

No.

## Is it a substantial burden for the maintainers to support this?

No.

## Related issue number

N/A

## Checklist

- [x] I think the code is well written
- [ ] Unit tests for the changes exist (N/A, no behaviour change;
existing iterator tests cover both kinds and directions)
- [ ] Documentation reflects the changes (N/A)
- [ ] If you provide code modification, please add yourself to
`CONTRIBUTORS.txt` (N/A)
- [x] Add a new news fragment into the `CHANGES/` folder
- [x] `make doc-spelling` passes and any new technical words are added
to `docs/spelling_wordlist.txt`

<details>
<summary>Agent run details (optional, for reviewers)</summary>

| Build | Operation | Before | After (`static inline`) | After
(`ALWAYS_INLINE`, not applied) |
|---|---|---|---|---|
| GIL | `iter_keys` | 48.2 | 48.2 (+0.00%) | 47.2 (-2.07%) |
| GIL | `iter_items` | 123.8 | 122.8 (-0.81%) | 122.8 (-0.81%) |
| FT | `iter_keys` | 80.9 | 83.9 (+3.71%) | 79.9... (continued)

793 of 1586 branches covered (50.0%)

Branch coverage included in aggregate %.

9353 of 10217 relevant lines covered (91.54%)

1.83 hits per line

Jobs
ID Job ID Ran Files Coverage
1 MyPy - 37602367403.1 07 Oct 2026 09:42AM UTC 98
85.96
GitHub Action Run
Source Files on build 37602367403
  • Tree
  • List 49
  • Changed 2
  • Source Changed 0
  • Coverage Changed 2
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #37602367403
  • fd33d408 on github
  • Prev Build on master (#37602143081)
  • Next Build on master (#37613370105)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc