{"record":{"id":"f989329e8d8c5f20","repo":"quarkusio/quarkus","slug":"set-command-must-be-in-the-form-key-value","errorCode":null,"errorMessage":"Set command must be in the form key=value","messagePattern":"Set command must be in the form key=value","errorType":"validation","errorClass":"CommandValidatorException","httpStatus":null,"severity":"error","filePath":"extensions/vertx-http/deployment/src/main/java/io/quarkus/vertx/http/deployment/devmode/ConsoleProcessor.java","lineNumber":230,"sourceCode":"                }\n            }\n            completerInvocation.setAppendSpace(false);\n            completerInvocation.addAllCompleterValues(possible);\n\n        }\n    }\n\n    public static class SetValidator implements CommandValidator<SetConfigCommand, CommandInvocation> {\n\n        @Override\n        public void validate(SetConfigCommand command) throws CommandValidatorException {\n            //-1 because the last char can't be equals\n            for (int i = 0; i < command.command.length() - 1; ++i) {\n                if (command.command.charAt(i) == '=') {\n                    return;\n                }\n            }\n            throw new CommandValidatorException(\"Set command must be in the form key=value\");\n        }\n    }\n}\n","sourceCodeStart":212,"sourceCodeEnd":234,"githubUrl":"https://github.com/quarkusio/quarkus/blob/e1c734241f34c7919086ceb4c9262b4a58f6de44/extensions/vertx-http/deployment/src/main/java/io/quarkus/vertx/http/deployment/devmode/ConsoleProcessor.java#L212-L234","documentation":"ConsoleProcessor's command validation for the dev-mode console 'set' command requires a '=' separator so the value can be split into key and value. CommandValidatorException is thrown when no '=' appears anywhere except possibly as the last character. This is a live dev-console input validation, not a build failure.","triggerScenarios":"Typing a 'set' command in the Quarkus dev console (dev mode terminal) whose command string contains no '=' character within its length minus the final char — e.g. 'set mykey' or 'set mykey='.","commonSituations":"Forgetting the value when setting a system property via the dev console; pasting commands that lost the '=value' portion; interactive typos.","solutions":["Enter the command as key=value, e.g. set quarkus.datasource.jdbc.url=jdbc:postgresql://localhost/test","Ensure the '=' is not the final character — a value after '=' is expected","Escape or quote values containing spaces per the console's syntax if needed"],"exampleFix":"// before (dev console input)\nset quarkus.log.level\n// after\nset quarkus.log.level=DEBUG","handlingStrategy":"validation","validationCode":"boolean validSetCommand(String cmd) {\n    int eq = cmd.indexOf('=');\n    return eq > 0 && eq < cmd.length() - 1; // key before '=', value after\n}","typeGuard":null,"tryCatchPattern":"try {\n    console.execute(command);\n} catch (CommandValidatorException e) {\n    // prompt user: command must be key=value\n}","preventionTips":["Always include a non-empty value: key=value, with '=' not the last character","Double-check pasted dev-console commands for lost '=value' suffixes","Remember the check scans the whole string for '=' anywhere except the final position — 'key=' still fails in spirit since the value is empty"],"tags":["quarkus","dev-mode","console","input-validation"],"backgroundTag":"invalid-input-format","analyzedSha":"e1c734241f34c7919086ceb4c9262b4a58f6de44","analyzedAt":"2026-09-05T17:01:29.979Z","contentChangedAt":"2026-09-05T17:01:29.979Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}