eval corpus loaders: JSON parse errors name no file or line

Open Beginner friendly
#81 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
85/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
typescript
Domain
testing

Research direction

Start in eval/run.ts at the JSON.parse calls on lines 432, 446, 456, and 478, then trace the four corpus loaders and the JSONL input they process. Add the shared parsing behavior so malformed entries report the file and line, and verify that all four loaders use it instead of bare JSON.parse(line).

Written by the indexing model from the issue text.

Description

Every corpus loader in eval/run.ts parses lines with a bare JSON.parse(line) (lines 432, 446, 456, 478). A malformed hand edit kills the run with a raw SyntaxError that names neither the file nor the line.

Fix: one helper that parses a JSONL file and rethrows with file:line. All four loaders call it.

Found by the review gate on #76. It predates that PR.

Dominant language
TypeScript
Stars
0
Forks
1
Avg merge
1h 20m
Merged PRs (30d)
32

Contributor guide

No contributing guide indexed for this repository

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.

More from STRML/omp-classifier

All issues in STRML/omp-classifier

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.