{"record":{"id":"1019ded6c65a09d8","repo":"pola-rs/polars","slug":"unknown-command-unknown","errorCode":null,"errorMessage":"unknown command: `{unknown}`","messagePattern":"unknown command: `(.+?)`","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/polars-plan/src/bin/dsl-schema.rs","lineNumber":66,"sourceCode":"            .expect(\"missing command [generate, update-hashes, check-hashes]\");\n        let path = args.next();\n\n        if let Some(unknown) = args.next() {\n            panic!(\"unknown argument: `{unknown}`\");\n        }\n\n        match cmd.as_str() {\n            \"generate\" => {\n                generate(path.unwrap_or(\"./dsl-schema.json\".to_owned()));\n            },\n            \"update-hashes\" => {\n                update_hashes(path.unwrap_or(DEFAULT_HASHES_PATH.to_owned()));\n            },\n            \"check-hashes\" => {\n                check_hashes(path.unwrap_or(DEFAULT_HASHES_PATH.to_owned()));\n            },\n            unknown => {\n                panic!(\"unknown command: `{unknown}`\");\n            },\n        }\n    }\n\n    /// Serializes the current DSL schema into a file at the given path.\n    ///\n    /// Any existing file at the path is overwritten.\n    fn generate(path: impl AsRef<Path>) {\n        let schema = DslPlan::dsl_schema();\n\n        let mut file = File::create(path).expect(\"failed to open the schema file for writing\");\n        serde_json::to_writer_pretty(&mut file, &schema).expect(\"failed to serialize the schema\");\n        writeln!(&mut file).expect(\"failed to write the last newline\");\n        file.flush().expect(\"failed to flush the schema file\");\n    }\n\n    /// Outputs the current DSL schema hashes into a file at the given path.\n    ///","sourceCodeStart":48,"sourceCodeEnd":84,"githubUrl":"https://github.com/pola-rs/polars/blob/fe841f959ef4d2ceefc05a310d33ed7b1ab24e5e/crates/polars-plan/src/bin/dsl-schema.rs#L48-L84","documentation":"After validating argument count, the binary matches the subcommand against \"generate\", \"update-hashes\", and \"check-hashes\". Any other first argument falls into the catch-all arm and panics with this message. It is a typo/unsupported-command guard.","triggerScenarios":"Running the binary with a first argument that is not one of the three supported commands, e.g. `dsl-schema gen`, `dsl-schema check`, `dsl-schema help`.","commonSituations":"Typos or abbreviations of subcommands, guessing command names, or scripts written against an older/newer CLI surface with different command names.","solutions":["Use one of the exact command names: `generate`, `update-hashes`, or `check-hashes`.","Fix typos (`gen` -> `generate`, `check` -> `check-hashes`).","Inspect crates/polars-plan/src/bin/dsl-schema.rs to see the current command list."],"exampleFix":"// before\ndsl-schema check hashes.json\n\n// after\ndsl-schema check-hashes hashes.json","handlingStrategy":"validation","validationCode":"const VALID = new Set([\"generate\", \"update-hashes\", \"check-hashes\"]);\nif (!VALID.has(cmd)) throw new Error(`unknown command: ${cmd}`);","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Use the exact command names; no abbreviations are accepted.","Keep a canonical invocation snippet in team docs/Makefile.","Check dsl-schema.rs source when unsure of the command list."],"tags":["cli","panic","invalid-command"],"backgroundTag":"invalid-cli-argument","analyzedSha":"fe841f959ef4d2ceefc05a310d33ed7b1ab24e5e","analyzedAt":"2026-09-18T22:14:11.667Z","contentChangedAt":"2026-09-18T22:14:11.667Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}