Skip to content

Commit

Permalink
formatting, comments.
Browse files Browse the repository at this point in the history
  • Loading branch information
apotonick committed Mar 23, 2024
1 parent 6f239cc commit 862021e
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions lib/trailblazer/workflow/advance.rb
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
# Runtime
module Trailblazer
module Workflow
# * Advance knows if an iteration was executed successfully or not (=> iteration set),
# hence the success/failure return signal.

# TODO:
# * wire the event_valid? step to {invalid_state} terminus and handle that differently in the endpoint.
class Advance < Trailblazer::Activity::Railway
# UNAUTHORIZED_SIGNAL = "unauthorized"
step task: :find_position_options
step task: :event_valid?, Output(:failure) => End(:not_authorized)
step task: :advance
Expand Down Expand Up @@ -34,8 +38,8 @@ def advance((ctx, flow_options), **circuit_options)
# FIXME: fix flow_options!

configuration, (ctx, flow_options) = Trailblazer::Workflow::Collaboration::Synchronous.advance(
[ctx, {throw: []}.merge(flow_options)], # FIXME: allow circuit_options?
circuit_options, # circuit_options
[ctx, {throw: []}.merge(flow_options)], # FIXME: allow circuit_options? test?
circuit_options,

**position_options,
message_flow: message_flow,
Expand Down

0 comments on commit 862021e

Please sign in to comment.