Skip to content

Exception in thread "main" java.lang.RuntimeException: unknown library: volley #3916

@pradeepkumarreddyk

Description

@pradeepkumarreddyk
Description

I have used the following dependency in android studio to download the swagger-codegen-cli jar file:-
compile "io.swagger:swagger-codegen-cli:2.1.4"

Then, I'm using the following command

Command line used for generation

java -jar swagger-codegen-cli-2.1.4.jar generate -i generate_upload.yml -l android --library=volley -o generated_code_for_upload_resource/ -c generate_config.json

and i'm getting the following exception:-

Exception in thread "main" java.lang.RuntimeException: unknown library: volley
at io.swagger.codegen.DefaultCodegen.setLibrary(DefaultCodegen.java:1637)
at io.swagger.codegen.config.CodegenConfigurator.toClientOptInput(CodegenConfigurator.java:307)
at io.swagger.codegen.cmd.Generate.run(Generate.java:186)
at io.swagger.codegen.SwaggerCodegen.main(SwaggerCodegen.java:35)

Swagger-codegen version

i'm using 2.1.4 version of swagger codegen

Steps to reproduce
  1. include the following dependency in android studio
    compile "io.swagger:swagger-codegen-cli:2.1.4"

this downloads the jar file.

  1. using this jar file, try to generate the code using the following command line

java -jar swagger-codegen-cli-2.1.4.jar generate -i generate_upload.yml -l android --library=volley -o generated_code_for_upload_resource/ -c generate_config.json

  1. I'm getting exception as unknown volley library

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions