onyx-platform/onyx

Exception-handling flow condition fails to compile in 0.12.x

neverfox opened this issue · 2 comments

Beginning with 0.12.0, tasks fail to compile if I introduce an initial flow condition like the following:

{:flow/from :my-task
 :flow/to :none
 :flow/thrown-exception? true
 :flow/short-circuit? true
 :flow/predicate ::always-true
 :flow/action :retry}

I get the following stacktrace:

Uncaught exception, not in assertion.
expected: nil
actual: clojure.lang.ExceptionInfo: Don't know how to create ISeq from: clojure.lang.Keyword
at clojure.lang.RT.seqFrom (RT.java:550)
clojure.lang.RT.seq (RT.java:530)
clojure.lang.LazySeq.seq (LazySeq.java:58)
clojure.lang.RT.seq (RT.java:528)
clojure.core$seq__5124.invokeStatic (core.clj:137)
clojure.core$reduce1.invokeStatic (core.clj:922)
clojure.core$set.invokeStatic (core.clj:4079)
clojure.core$set.invoke (core.clj:4071)
onyx.peer.task_compile$flow_conditions__GT_event_map.invokeStatic (task_compile.clj:35)
onyx.peer.task_compile$flow_conditions__GT_event_map.invoke (task_compile.clj:30)
onyx.peer.task_lifecycle$compile_task.invokeStatic (task_lifecycle.clj:1172)
onyx.peer.task_lifecycle$compile_task.invoke (task_lifecycle.clj:1161)
onyx.peer.task_lifecycle.TaskLifeCycle.start (task_lifecycle.clj:1236)
com.stuartsierra.component$fn__11554$G__11548__11556.invoke (component.cljc:5)
com.stuartsierra.component$fn__11554$G__11547__11559.invoke (component.cljc:5)
clojure.lang.AFn.applyToHelper (AFn.java:154)
clojure.lang.AFn.applyTo (AFn.java:144)
clojure.lang.Var.applyTo (Var.java:702)
clojure.core$apply.invokeStatic (core.clj:659)
clojure.core$apply.invoke (core.clj:652)
com.stuartsierra.component$try_action.invokeStatic (component.cljc:117)
com.stuartsierra.component$try_action.invoke (component.cljc:116)
com.stuartsierra.component$update_system$fn__11605.invoke (component.cljc:139)
clojure.lang.ArraySeq.reduce (ArraySeq.java:114)
clojure.core$reduce.invokeStatic (core.clj:6747)
clojure.core$reduce.invoke (core.clj:6730)
com.stuartsierra.component$update_system.invokeStatic (component.cljc:135)
com.stuartsierra.component$update_system.doInvoke (component.cljc:129)
clojure.lang.RestFn.invoke (RestFn.java:445)
com.stuartsierra.component$start_system.invokeStatic (component.cljc:163)
com.stuartsierra.component$start_system.invoke (component.cljc:155)
onyx.system.OnyxTask/fn (system.clj:101)
onyx.system$rethrow_component.invokeStatic (system.clj:67)
onyx.system$rethrow_component.invoke (system.clj:65)
onyx.system.OnyxTask.start (system.clj:100)
onyx.log.commands.common$start_task_BANG_$fn__24252.invoke (common.clj:127)
clojure.core.async$thread_call$fn__7204.invoke (async.clj:442)
clojure.lang.AFn.run (AFn.java:22)
java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1149)
java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:624)
java.lang.Thread.run (Thread.java:748

No issue in 0.11.x or less.

Ah, I see. Is there a new best practice for "handle any unexpected failure" where you want to retry? Also, is there a time table for 0.12 doc updates?