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

AbstractMethodError from README example #25

Open
AdamFrey opened this issue Feb 9, 2016 · 2 comments
Open

AbstractMethodError from README example #25

AdamFrey opened this issue Feb 9, 2016 · 2 comments

Comments

@AdamFrey
Copy link
Contributor

AdamFrey commented Feb 9, 2016

I fired up a bare repl, required silk and silk.serve and pasted this example from the README:

(def api-routes
  (silk/routes {:api-data [["api"] {"limit" (silk/? (silk/int :limit) {:limit 100})
                                    "offset" (silk/? (silk/int :offset) {:offset 0})} (serve/POST)]}))

and the result is:

clojure.lang.Compiler$CompilerException: java.lang.AbstractMethodError, compiling:(boot.user4378993532146088720.clj:3:87)
          java.lang.AbstractMethodError:

any thoughts on why I'm seeing this?

@domkm
Copy link
Owner

domkm commented Feb 11, 2016

Thanks for the report, @AdamFrey. I just pushed 1.1.2 to Clojars. It resolves this issue for me. Try it out.

@AdamFrey
Copy link
Contributor Author

I no longer get the AbstractMethodError on 1.1.2, but the example still doesn't work for me:

boot.user=> (def api-routes
       #_=>   (silk/routes {:api-data [["api"] {"limit" (silk/? (silk/int :limit) {:limit 100})
       #_=>                                     "offset" (silk/? (silk/int :offset) {:offset 0})} (serve/POST)]}))
#'boot.user/api-routes
boot.user=> (silk/match api-routes {:path ["api"]})
nil
boot.user=> (silk/match api-routes {:path ["api"] :request-method :post})
nil

@AdamFrey AdamFrey reopened this Feb 11, 2016
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

2 participants