cognitect-labs / vase

Data driven microservices
Eclipse Public License 1.0
373 stars 42 forks source link

Vasebi sample throws a NullPointerException when loading the root url. #63

Closed ddeaguiar closed 5 years ago

ddeaguiar commented 7 years ago

Description

The application errors when following the Getting Started section of the README.

Expected Behavior

It should not error.

Actual Behavior

I get this error:

clojure.lang.ExceptionInfo: Interceptor Exception:
    at clojure.core$ex_info.invokeStatic(core.clj:4725)
    at clojure.core$ex_info.invoke(core.clj:4725)
...
Caused by: java.lang.NullPointerException: null
    at clojure.lang.Numbers.divide(Numbers.java:3796)
    at vasebi.server$eval17758$fn__17759$fn__17760.invoke(server.clj:45)
    at clojure.core$mapv$fn__9368.invoke(core.clj:6788)
    at clojure.lang.PersistentVector.reduce(PersistentVector.java:341)
    at clojure.core$reduce.invokeStatic(core.clj:6703)
    at clojure.core$mapv.invokeStatic(core.clj:6779)
    at clojure.core$mapv.invoke(core.clj:6779)
    at vasebi.server$eval17758$fn__17759.invoke(server.clj:45)
    at io.pedestal.interceptor.chain$try_f.invokeStatic(chain.clj:52)

Steps to reproduce

Follow the steps in the Getting Started section of the sample's README.

Environment

Operating System (including version).

macOS 10.12.3

Your current Leiningen/Boot/Maven version (lein --version)

Leiningen 2.7.1 on Java 1.8.0_112 Java HotSpot(TM) 64-Bit Server VM

Pedestal and Vase version

Refer to the sample's project.clj

[io.pedestal/pedestal.service "0.5.2"] [com.cognitect/pedestal.vase "0.9.1-SNAPSHOT"]

ddeaguiar commented 7 years ago

This is the only sample that depends on a Vase snapshot release. I think we should do two things:

  1. Samples should depend on a stable Vase release.
  2. Run integration tests during builds to verify that samples behave as expected.
ddeaguiar commented 5 years ago

I updated the samples deps and can't reproduce the issue.