{"record":{"id":"6db5c41f51e78c94","repo":"OpenAPITools/openapi-generator","slug":"invalid-library-option-specified-library-m","errorCode":null,"errorMessage":"Invalid 'library' option specified: '{library}'. Must be 'httpclient' or 'volley' (default)","messagePattern":"Invalid 'library' option specified: '(.+?)'\\. Must be 'httpclient' or 'volley' \\(default\\)","errorType":"validation","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AndroidClientCodegen.java","lineNumber":508,"sourceCode":"        // need to put back boolean properties into additionalProperties as the values in additionalProperties are strings\n        additionalProperties.put(CodegenConstants.SERIALIZABLE_MODEL, serializableModel);\n        additionalProperties.put(USE_ANDROID_MAVEN_GRADLE_PLUGIN, useAndroidMavenGradlePlugin);\n\n        //make api and model doc path available in mustache template\n        additionalProperties.put(\"apiDocPath\", apiDocPath);\n        additionalProperties.put(\"modelDocPath\", modelDocPath);\n\n        if (StringUtils.isEmpty(getLibrary())) {\n            setLibrary(\"volley\"); // set volley as the default library\n        }\n\n        // determine which file (mustache) to add based on library\n        if (\"volley\".equals(getLibrary())) {\n            addSupportingFilesForVolley();\n        } else if (\"httpclient\".equals(getLibrary())) {\n            addSupportingFilesForHttpClient();\n        } else {\n            throw new IllegalArgumentException(\"Invalid 'library' option specified: '\" + getLibrary() + \"'. Must be 'httpclient' or 'volley' (default)\");\n        }\n    }\n\n    @Override\n    public String escapeQuotationMark(String input) {\n        // remove \" to avoid code injection\n        return input.replace(\"\\\"\", \"\");\n    }\n\n    @Override\n    public String escapeUnsafeCharacters(String input) {\n        return input.replace(\"*/\", \"*_/\").replace(\"/*\", \"/_*\");\n    }\n\n    private void addSupportingFilesForVolley() {\n        // documentation files\n        modelDocTemplateFiles.put(\"model_doc.mustache\", \".md\");\n        apiDocTemplateFiles.put(\"api_doc.mustache\", \".md\");","sourceCodeStart":490,"sourceCodeEnd":526,"githubUrl":"https://github.com/OpenAPITools/openapi-generator/blob/fcec517be3cf5b7964296bcba25fbc97541484e7/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AndroidClientCodegen.java#L490-L526","documentation":"Error \"Invalid 'library' option specified: '{library}'. Must be 'httpclient' or 'volley' (default)\" thrown in OpenAPITools/openapi-generator.","triggerScenarios":"Thrown when the 'library' option for the Android client generator is set to something other than 'httpclient' or 'volley'. Set library=httpclient or library=volley (the default).","commonSituations":"See trigger scenarios.","solutions":["Set the 'library' option to 'httpclient' or 'volley', e.g. '--library volley', or remove it to use the default 'volley'."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"fcec517be3cf5b7964296bcba25fbc97541484e7","analyzedAt":"2026-08-22T11:13:11.613Z","schemaVersion":2},"datasetVersion":"2026-08-22T14:17:55.899Z"}