Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scalatra 2.3.1 Swagger breaking change? #94

Closed
futurechimp opened this issue May 23, 2015 · 2 comments
Closed

Scalatra 2.3.1 Swagger breaking change? #94

futurechimp opened this issue May 23, 2015 · 2 comments

Comments

@futurechimp
Copy link
Member

Hi guys,

When I attempt to use Scalatra 2.3.1+ with Swagger according to what's currently in the docs, I get the following error:

[info] Compiling 3 Scala sources to /Users/dave/workspace/foss/scalatra-website-examples/2.3/swagger-example/target/scala-2.11/classes...
[error] /Users/dave/workspace/foss/scalatra-website-examples/2.3/swagger-example/src/main/scala/org/scalatra/example/swagger/FlowersController.scala:14: class FlowersController needs to be abstract, since method render in trait JsonMethods of type (value: org.json4s.JValue)(implicit formats: org.json4s.Formats)scala.text.Document is not defined
[error] class FlowersController(implicit val swagger: Swagger) extends ScalatraServlet with NativeJsonSupport with SwaggerSupport  {
[error]       ^
[error] /Users/dave/workspace/foss/scalatra-website-examples/2.3/swagger-example/src/main/scala/org/scalatra/example/swagger/FlowersSwagger.scala:7: class ResourcesApp needs to be abstract, since method render in trait JsonMethods of type (value: org.json4s.JValue)(implicit formats: org.json4s.Formats)scala.text.Document is not defined
[error] class ResourcesApp(implicit val swagger: Swagger) extends ScalatraServlet with NativeSwaggerBase
[error]       ^
[error] two errors found

@rossabaker @casualjim @seratch any idea what fixes these? I'd like to document the fix, currently all our Swagger docs will fail for anyone who generates a project and tries to follow the docs.

@futurechimp
Copy link
Member Author

To repro it, just change the dependency to to 2.3.1 in the Swagger project in the repo scalatra/scalatra-website-examples.

@futurechimp
Copy link
Member Author

Aha. Sorry for the noise. json4s 3.2.11, obviously, is the answer here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant