perf(xlsx): the sheet filter's attribute scan is slower since the parser-equivalent tokenizer
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 55/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- javascript, node.js
- Domain
- backend, performance
Research direction
Start by profiling with npm run bench -w pivotkit-xlsx; the issue points to packages/pivotkit-xlsx/src/xml.js, especially eachAttr and tagEnd. Compare the results with the figures in docs/reference/plugins.md, then investigate ways to speed up the attribute scan while preserving what it accepts. Done means the benchmark figures are current, the scan is faster, and the advisory tests still pass.
Written by the indexing model from the issue text.
Description
read() of a sheet formatted down to row 900,000 got slower with the parser-equivalent tokenizer from the GHSA-c6vh-q36c-92r3 fix:
| Commit | read() |
|---|---|
| 730e60a (before the fix) | 0.66 s |
| 9ec50d4 and later | 0.80 s |
Under V8 coverage it takes about twice as long. That pushed the old absolute time bound in the used-range test over its limit on CI, which #404 / #405 fixed.
Most of the time goes to eachAttr and tagEnd in packages/pivotkit-xlsx/src/xml.js. The benchmark figures in docs/reference/plugins.md (4.4 s / 4.0 s for the 52 MB case) predate the fix and may be stale.
To do:
- Profile with
npm run bench -w pivotkit-xlsxand update the docs figures. - Speed up the attribute scan without changing what it accepts. The equivalence with the parser is the security property, so the advisory's tests must stay green.
- Dominant language
- JavaScript
- Stars
- 1
- Forks
- 1
- Avg merge
- 3h 21m
- Merged PRs (30d)
- 250
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from eizedev/pivotkit
-
accessibility area:react bug
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
Maintainers usually reply within 1 day
-
area:tests
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day
-
area:cli bug
Difficulty 2/5 1-3 hours Newbie friendliness 83/100
Maintainers usually reply within 1 day
-
area:cli enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
area:react enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
All issues in eizedev/pivotkit
Similar issues
-
Difficulty 1/5 1-3 hours Newbie friendliness 88/100
mattabate/life-distributable#231 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
sfbrigade/pocket-gardens#60 ·
Maintainers usually reply within 5 days
-
The print preview leaves writing space short by the margins of hidden headers, footers and solutionsOpen
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
PreTeXtBook/pretext#3329 ·
Maintainers usually reply within 1 day
-
bug good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
devarshishimpi/codra#178 ·
Maintainers usually reply within 1 day