softwaremill / livestub Goto Github PK
View Code? Open in Web Editor NEWThe HTTP server stub you always wanted!
The HTTP server stub you always wanted!
I'm trying to run livestub server from openapi file by using command:
coursier launch com.softwaremill.sttp.livestub:livestub-app_2.13:0.2.1 -- -p 7070 --openapi-spec openApi.json
I'm receiving error:
java.lang.RuntimeException: DecodingFailure(Missing required field, List(DownField(version), DownField(info))) at sttp.livestub.app.LiveStubLauncher$.$anonfun$main$1(LiveStubLauncher.scala:33) at sttp.livestub.app.LiveStubLauncher$.$anonfun$main$1$adapted(LiveStubLauncher.scala:29) at cats.SemigroupalArityFunctions.$anonfun$map4$1(SemigroupalArityFunctions.scala:60) at cats.data.Validated.ap(Validated.scala:522) at cats.data.ValidatedApplicative.ap(Validated.scala:1082) at cats.data.ValidatedApplicative.ap(Validated.scala:1075) at cats.ComposedApply.$anonfun$ap$2(Composed.scala:54) at cats.instances.Function0Instances$$anon$4.$anonfun$ap$1(function.scala:105) at com.monovore.decline.Parser.evalResult(Parser.scala:30) at com.monovore.decline.Parser.consumeAll(Parser.scala:116) at com.monovore.decline.Parser.apply(Parser.scala:19) at com.monovore.decline.Command.parse(opts.scala:20) at com.monovore.decline.effect.CommandIOApp$.$anonfun$run$4(CommandIOApp.scala:45) at use @ sttp.livestub.app.LiveStubLauncher$.$anonfun$main$1(LiveStubLauncher.scala:39) at map @ com.monovore.decline.effect.CommandIOApp$.$anonfun$run$7(CommandIOApp.scala:48) at delay @ com.monovore.decline.effect.CommandIOApp$.run(CommandIOApp.scala:43) at flatMap @ com.monovore.decline.effect.CommandIOApp$.run(CommandIOApp.scala:42) Caused by: DecodingFailure(Missing required field, List(DownField(version), DownField(info)))
What i'm doing wrong?
This is a trivial issue, but the "stubbing from code" section of the readme contains the following example for adding livestub as a dependency:
libraryDependencies += "com.softwaremill.sttp.livestub" % "livestub-sdk" % "0.1.18"
This does not work as-written, due to not specifying the Scala version. It should be:
libraryDependencies += "com.softwaremill.sttp.livestub" %% "livestub-sdk" % "0.1.18"
Basically given an openAPI spec document, provide a simple way to load it and stub it.
when trying to publish docker image from a snapshot version following error occurs:
[error] invalid argument "softwaremill/sttp.livestub:0.1.11+242-3d4a132f-SNAPSHOT" for "-t, --tag" flag: invalid reference format
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.