mirror of
https://github.com/CCExtractor/ccextractor.git
synced 2026-02-03 21:23:48 +00:00
[PR #1997] fix Prevent command-line panics on malformed user input #2797
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/CCExtractor/ccextractor/pull/1997
Author: @THE-Amrit-mahto-05
Created: 1/8/2026
Status: 🔄 Open
Base:
master← Head:fix/parser-cli-panics📝 Commits (6)
d3296f0fix prevent command line panics on malformed user input4eb36cereplace fatal! with panic/expect for clap-validated inputs070d7a1rustfmt4fa94eamove CLI validation to clap value_parser and remove panic/fatal in parser.rs3c49010cargo fmt i forget fixing thate862697re run checks📊 Changes
2 files changed (+294 additions, -208 deletions)
View changed files
📝
src/rust/src/args.rs(+220 -33)📝
src/rust/src/parser.rs(+74 -175)📄 Description
In raising this pull request, I confirm the following (please check boxes):
My familiarity with the project is as follows (check one):
Description
fixes multiple panic scenarios in
parser.rscaused by malformed or unexpectedcommand-line arguments.
Issues fixed
--usercolorunwrap()panics when parsing numeric CLI valuesfatal!(MalformedParameter)errorsImpact
Changes made
unwrap()calls with safe error handlingVerification
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.