Remove extra list copying
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 30/100
Research direction
The issue names no files or tests. Start by locating the places where token iterables are wrapped in list() and determine which materializations are unnecessary; done means those lists are no longer created unless needed for parser state, without changing lexer behavior.
Written by the indexing model from the issue text.
Description
(Filing this mostly as a reminder after taking a quick look at the code)
A bunch of places materialize Python lists of tokens unnecessarily (by calling list() on some iterable).
This isn't a huge deal as we likely will never really need to deal with giant schemas, but it's unnecessary.
We should instead only do this if/when we ever need to (e.g. to maintain state for our additional parsing).
- Dominant language
- Python
- Stars
- 1
- Forks
- 1
- PR merge metrics
- No merged PRs in 30d
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
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 python-jsonschema/jsonschema-lexer
-
enhancement
Difficulty 3/5 1-2 days Newbie friendliness 45/100
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
python-jsonschema/jsonschema-lexer#2 · 11 comments · 1 reaction ·
All issues in python-jsonschema/jsonschema-lexer
Similar issues
-
Difficulty 1/5 1-3 hours Newbie friendliness 78/100
web-push-libs/pywebpush#216 · 1 comment ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
AgriciDaniel/claude-seo#572 ·
Maintainers usually reply within 5 days
-
area:print-dispatch
Difficulty 2/5 1-3 hours Newbie friendliness 92/100
Maintainers usually reply within 1 day
-
area: docs domain: technical-writing good first issue type: documentation
Difficulty 2/5 1-3 hours Newbie friendliness 80/100
Deepak3699/Ai_Mentor#919 ·
Maintainers usually reply within 2 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day