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

aio-libs / multidict / 36395529450
87%

Build:
DEFAULT BRANCH: master
Ran 28 Sep 2026 08:08AM UTC
Jobs 1
Files 45
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

28 Sep 2026 08:07AM UTC coverage: 87.175% (-0.009%) from 87.184%
36395529450

push

github

web-flow
Benchmark re-initializing a populated multidict (#1620)

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

## What do these changes do?

Adds `reinit_items` (`d.__init__(items)`) and `reinit_clone`
(`d.__init__(other)` with `other` of the same kind, the
`md_clone_from_ht()` path) to `benchmarks/operations.py`, each at 200
and 20 items, plus four matching CodSpeed benchmarks. The existing
`ctor_*` rows always build a fresh object whose table is empty, so
replacing a live table (`_md_install_keys()`, #1619) was never measured;
#1619 needed a one-off script.

The target stays populated after each call, so the setup hands back the
same object and nothing is rebuilt inside the timed region. The rows are
multidict-only: `dict.__init__` on a live dict updates rather than
replaces. Multidict-only rows are not rendered into
`docs/benchmark.rst`, so the tables keep their shape and are not
regenerated; the exclusion paragraph gained one sentence saying why
re-initializing is left out. The CodSpeed tests carry no shard mark and
run in shard 1 next to the `create_*` benchmarks; recent runs show the
two shards within a few percent of each other on both builds.

## Are there changes in behavior for the user?

No.

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

No; four rows in the registry and four CodSpeed tests following the
existing patterns.

## Related issue number

Follow-up to #1619.

## Checklist

- [x] I think the code is well written
- [x] Unit tests for the changes exist (`callgrind_driver.py
--self-check` asserts the re-initialized size)
- [x] Documentation reflects the changes
- [ ] 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`

Drafted with Claude Code (Claude Opus 5.5); reviewed by @asvetlov.

<details>
<summary>Agent run details (optional, for re... (continued)

780 of 1560 branches covered (50.0%)

Branch coverage included in aggregate %.

20 of 24 new or added lines in 1 file covered. (83.33%)

8553 of 9146 relevant lines covered (93.52%)

1.87 hits per line

Uncovered Changes

Lines Coverage ∆ File
4
99.38
-0.62% tests/test_multidict_benchmarks.py
Jobs
ID Job ID Ran Files Coverage
1 MyPy - 36395529450.1 28 Sep 2026 08:08AM UTC 90
87.17
GitHub Action Run
Source Files on build 36395529450
  • Tree
  • List 45
  • Changed 3
  • Source Changed 1
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #36395529450
  • e04369b1 on github
  • Prev Build on master (#36395466942)
  • Next Build on master (#36402130758)
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