[PROPOSAL] Test every command-line option, including what the C code receives
Maintainers usually reply within 7 days
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 42/100
Research direction
Start by reading the existing argument tests from #2041 and the Rust parser in args.rs; trace how ccxr_parse_parameters passes settings into the C ccx_options structure. The proposal is split into small PRs: add a helper for checking C values, detect options without tests, then cover untested options and legacy spellings. Done means these paths and options have regression tests; coordinate with the author, who says they plan to work on it.
Written by the indexing model from the issue text.
Description
The Sample Platform NG page says: "We are not testing every possible argument... We broke some things on the rust migration that apparently flew under the radar."
Since the Rust argument parser replaced the C one, a number of options have broken without any test noticing:
- old spellings rejected (#2367), negative
--delay(#2370),ccextractor.cnfignored (#2369) --sentencecap/--kfmissing most words (#2397)- bad time values crashing (#2374, #2386),
--sendto/--buffersize(#2393) - still on master:
--defaultcolor,-smi,--streamtype 0x24, combined debug flags (fixes ready)
Why the current tests (#2041) didn't catch these:
- About 38 of 171 options have no test at all, e.g.
--defaultcolor,--smi,--stream,--stdin,--udp,--tcp. - No test checks what the C code receives. The tests check the Rust
Optionsafter parsing, but bugs like--defaultcolor(wrong C type) and--sentencecap(list not sorted for C'sbsearch) happen when the settings are handed to C. - Most tests skip the real entry path (
ccxr_parse_parameters, including the legacy-spelling conversion), which is how--delay -500went unnoticed.
I'd like to add, in small PRs:
- A test helper that runs options through the real path (
ccxr_parse_parameters→ Cccx_options) and checks the C values. - A test that fails when an option in
args.rshas no test, so new options can't be added untested. - Tests for the untested options, plus the old v0.94 spellings.
Does this direction sound good? i will work on this
- Dominant language
- C
- Stars
- 919
- Forks
- 604
- Avg merge
- 13d 12h
- Merged PRs (30d)
- 7
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 CCExtractor/ccextractor
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
CCExtractor/ccextractor#2478 ·
Maintainers usually reply within 7 days
-
[BUG] encoders: WebVTT encoder generates invalid ## delimiter and malformed @import violating W3C specificationPossibly taken @yasar710 claimed this 5 days ago. Open
Difficulty 1/5 Under an hour Newbie friendliness 88/100
CCExtractor/ccextractor#2465 · 2 comments ·
Maintainers usually reply within 7 days
-
[BUG] MXF: update_tid_lut() writes past tracks[32] onto nb_tracks, turning a file-supplied track id into the write offsetPossibly taken @pranayr710 claimed this 12 days ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
CCExtractor/ccextractor#2457 ·
Maintainers usually reply within 7 days
-
[Security] Heap buffer overflow (OOB read past GPAC sample buffer) in process_avc_sample() at mp4.c:99 when parsing a crafted MP4 filePossibly taken @yasar710 claimed this 18 days ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
CCExtractor/ccextractor#2449 ·
Maintainers usually reply within 7 days
-
[BUG] DVB subtitle decoder: heap-buffer-overflow write in dvbsub_parse_clut_segment via unbounded entry_idPossibly taken @Aditya-Saroha claimed this 21 days ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
CCExtractor/ccextractor#2440 ·
Maintainers usually reply within 7 days
All issues in CCExtractor/ccextractor
Similar issues
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
python-pillow/Pillow#10590 ·
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
openwrt/packages#31407 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day