{"record":{"id":"912ed151c36df5cc","repo":"Morganamilo/paru","slug":"option-does-not-take-a-value","errorCode":null,"errorMessage":"option '{}' does not take a value","messagePattern":"option '(.+?)' does not take a value","errorType":"validation","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"src/config.rs","lineNumber":1153,"sourceCode":"                for word in value?.split_whitespace() {\n                    self.no_warn_builder.add(Glob::new(word)?);\n                }\n            }\n            \"Mode\" => {\n                for word in value?.split_whitespace() {\n                    self.mode |= word.parse()?;\n                }\n            }\n            _ => ok2 = false,\n        };\n\n        if !(ok1 || ok2) {\n            eprintln!(\n                \"{}\",\n                tr!(\"error: unknown option '{}' in section [options]\", key)\n            )\n        } else {\n            ensure!(\n                ok1 || has_value,\n                tr!(\"option '{}' does not take a value\", key)\n            );\n        }\n        Ok(())\n    }\n\n    pub fn aur_namespace(&self) -> &str {\n        if self.pacman.repos.iter().any(|r| r.name == \"aur\") {\n            // hack for search install\n            \"__aur__\"\n        } else {\n            \"aur\"\n        }\n    }\n}\n\npub fn version() {","sourceCodeStart":1135,"sourceCodeEnd":1171,"githubUrl":"https://github.com/Morganamilo/paru/blob/9ac3578807a87858651e81a02586ceb947686e7c/src/config.rs#L1135-L1171","documentation":"When parsing the [options] section of the config, each key must be a known option and, if it is a boolean-style option (ok1), it must not be given an explicit value. This error means the user supplied `option = value` (has_value) for an option that does not take one.","triggerScenarios":"A line like `SomeFlag = true` in the [options] section of paru.conf where SomeFlag is a flag-style option parsed via parse_options's ok1 branch.","commonSituations":"Users copying pacman.conf-style syntax into paru.conf; adding `= true`/`= yes` to boolean options after a paru version changed option parsing.","solutions":["Remove the value from the option in [options]: write just the option name","Check `man paru.conf` for which options take values and which are flags","Upgrade/downgrade paru if the option semantics changed between versions"],"exampleFix":"// before (paru.conf [options])\nSudoLoop = true\n// after\n[options]\nSudoLoop","handlingStrategy":"validation","validationCode":"// ensure flag-style [options] entries have no '=' value\nconst FLAG_OPTIONS: &[&str] = &[\"SudoLoop\", \"Devel\", \"CleanAfter\"];\nfn takes_value(option: &str) -> bool { !FLAG_OPTIONS.contains(&option) }","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Write boolean options without '= value' in paru.conf","Consult man paru.conf for option arity","Diff your config against a fresh example after upgrading paru"],"tags":["config","cli","parsing"],"backgroundTag":"invalid-config-value","analyzedSha":"9ac3578807a87858651e81a02586ceb947686e7c","analyzedAt":"2026-09-12T04:57:59.861Z","contentChangedAt":"2026-09-12T04:57:59.861Z","schemaVersion":2},"datasetVersion":"2026-09-16T09:17:16.951Z"}