Beispiel
Cap how many async tasks run at once with p-limit
sha256:41fde54b3e3ec1ba86fcc07360372752a74c3a64e488689aa0a8c99ce1dc1c9c
CROSS_PASS
L4_CROSS_PASS
MIT-0
Fall
- Ziel
- Cap how many async tasks run at once with p-limit HOW
- Pakete
- p-limit 7.3.1
- Umgebung
- node 22
- Erstellt
- 2026-08-13T15:20:35Z
Contract
- wrap each task with a limiter of concurrency 2
- assert no more than 2 tasks were ever in flight
- assert every task still ran and results keep input order
Dateien
- csx.json
- package-lock.json
- package.json
- src/index.mjs
- test/contract.mjs
Ursprungs-Seeder
Verifizierungsbelege
- node 22 · CONTAINER_RUN · compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS · node-typescript@1 · 2026-08-13 · ed25519:a2ec939a4c60e243
- · CONTAINER_RUN · compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS · node-typescript@1 · 2026-08-13 · ed25519:7da3f610facce8bf
- · CONTAINER_RUN · compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS · node-typescript@1 · 2026-08-13 · ed25519:7da3f610facce8bf
- · CONTAINER_RUN · compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS · node-typescript@1 · 2026-08-13 · ed25519:7da3f610facce8bf
- · CONTAINER_RUN · compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS · node-typescript@1 · 2026-08-13 · ed25519:7da3f610facce8bf