Module: Trailblazer::Developer::Debugger::Normalizer::Default
- Defined in:
- lib/trailblazer/developer/debugger/normalizer.rb
Overview
Default steps for the Debugger::Node options pipeline, following the step-interface.
Class Method Summary collapse
- .compile_id(ctx, activity:, task:) ⇒ Object
- .data(ctx, data: {}) ⇒ Object
- .incomplete?(ctx, trace_node:) ⇒ Boolean
- .label(ctx, label: nil, runtime_id:) ⇒ Object
- .runtime_id(ctx, compile_id:) ⇒ Object
Class Method Details
.compile_id(ctx, activity:, task:) ⇒ Object
26 27 28 |
# File 'lib/trailblazer/developer/debugger/normalizer.rb', line 26 def self.compile_id(ctx, activity:, task:, **) ctx[:compile_id] = Activity::Introspect.Nodes(activity, task: task)[:id] end |
.data(ctx, data: {}) ⇒ Object
38 39 40 |
# File 'lib/trailblazer/developer/debugger/normalizer.rb', line 38 def self.data(ctx, data: {}, **) ctx[:data] = data end |
.incomplete?(ctx, trace_node:) ⇒ Boolean
42 43 44 |
# File 'lib/trailblazer/developer/debugger/normalizer.rb', line 42 def self.incomplete?(ctx, trace_node:, **) ctx[:incomplete?] = trace_node.is_a?(Developer::Trace::Node::Incomplete) end |
.label(ctx, label: nil, runtime_id:) ⇒ Object
34 35 36 |
# File 'lib/trailblazer/developer/debugger/normalizer.rb', line 34 def self.label(ctx, label: nil, runtime_id:, **) ctx[:label] = label || runtime_id end |
.runtime_id(ctx, compile_id:) ⇒ Object
30 31 32 |
# File 'lib/trailblazer/developer/debugger/normalizer.rb', line 30 def self.runtime_id(ctx, compile_id:, **) ctx[:runtime_id] = compile_id end |