mapbox / mapbox/tilelive

list: concurrency test sometimes fails

Open
#151 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
540
Forks
106
PR merge metrics
No merged PRs in 30d

Description

It's not consistent, but the "list: concurrency" test in stream-list.test.js sometimes fails:

```
# list: concurrency
not ok 243 concurrency 10
---
operator: deepEqual
expected: |-
{ done: 30, ops: 40, skipped: 14, total: 77 }
actual: |-
{ done: 20, ops: 30, skipped: 9, total: 77 }
at: null._onTimeout (/builddir/build/BUILD/tilelive-5.11.0/test/stream-list.test.js:105:11)
...
```

I assume it's something to do with the precise timing, given the test seems to be looking at how much work is done, given rate limited streams, in a given amount of time.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with test/stream-list.test.js, especially the "list: concurrency" test and the assertion around line 105. Run the test repeatedly to reproduce the intermittent deepEqual failure, then inspect how its timing-sensitive work count is measured. Done means the concurrency test passes reliably across repeated runs.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
testing-qa
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.