tasker-rb 0.1.6-x86_64-linux → 0.1.7-x86_64-linux

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6ad2e7070082b3ce68f86829a83781eaf94b1fbcecfe32bcbbd3f3c668d47d25
4
- data.tar.gz: 05ac453ea270917bfafc5558e430d6129b2abba4aaffda3ec58467c60c5725d4
3
+ metadata.gz: ef76abda3b0f0b478e4eaa31e4dfda4730971f67f32834bb94529af8139a7578
4
+ data.tar.gz: 3b6abe2f8fe5560df69c4339b53cd2f7226b4bafcb9457e6a598bf594818e700
5
5
  SHA512:
6
- metadata.gz: 4c8796a036d3ed7e9cfd5818c09ebd8677b7a841721e6e36cce81d787280390d1a8dcd5e312e688f2602afc40d44fc5c560ad5c74039d327f4456a355d8ec779
7
- data.tar.gz: 5a8b5d080096c7ba5c106e59056132ba8e72319bb0775a2de096c10acb1185bde3cbda0672d800a8d71fe9c5e1c11c4a4802adcb0cd9a640dab8e7b38634af75
6
+ metadata.gz: b818d34abcfcdbe664844373dc0a28efc48df10a29858553288d65371d2def98532d5e189b453c4582d173f0e1d169c996e16271ddfb8f1952b5592f2eedbfe8
7
+ data.tar.gz: afec9ba13cf2f9e9957ab521baed47f865f12af391d4cc1a9545f295c7b45f93b296048614d8c22f37e8caaebfd5bfef977d4105a5d4b1a79e599e1a253c0bd8
@@ -192,8 +192,13 @@ module TaskerCore
192
192
  #
193
193
  # @param results_data [Hash] Hash of step names to their results
194
194
  def initialize(results_data)
195
- # Use HashWithIndifferentAccess for developer-friendly key access
196
- @results = (results_data || {}).with_indifferent_access
195
+ # Use HashWithIndifferentAccess for developer-friendly key access.
196
+ # serde_magnus serializes Rust struct field names as Ruby symbols, so
197
+ # each inner StepExecutionResult hash has symbol keys (:result, :success, etc.).
198
+ # Convert them to indifferent access so callers can use string or symbol keys.
199
+ raw = results_data || {}
200
+ @results = raw.transform_values { |v| v.is_a?(Hash) ? v.with_indifferent_access : v }
201
+ .with_indifferent_access
197
202
  end
198
203
 
199
204
  # Get result from a parent step (returns full result hash)
@@ -136,7 +136,9 @@ module TaskerCore
136
136
  # Convert to plain Hash first — ActiveSupport::HashWithIndifferentAccess
137
137
  # stores keys as strings internally even after transform_keys(&:to_sym),
138
138
  # which causes Dry::Struct to silently ignore all attributes.
139
- symbolized = Hash(raw).transform_keys(&:to_sym)
139
+ # Hash() is a no-op on HWIA (since it IS-A Hash); .to_h produces
140
+ # a true plain Hash so symbol keys actually stick.
141
+ symbolized = raw.to_h.transform_keys(&:to_sym)
140
142
  known = model_cls.attribute_names
141
143
  model_cls.new(**symbolized.slice(*known))
142
144
  else
Binary file
@@ -171,9 +171,7 @@ module TaskerCore
171
171
 
172
172
  # Extract all callable references
173
173
  def all_callables
174
- callables = []
175
- steps.each { |step| callables << step.handler.callable }
176
- callables
174
+ steps.map { |step| step.handler.callable }
177
175
  end
178
176
 
179
177
  # Check if template is valid for registration
@@ -3,7 +3,7 @@
3
3
  module TaskerCore
4
4
  # Version synchronization with the core Rust crate
5
5
  # This should be kept in sync with the Cargo.toml version
6
- VERSION = '0.1.6'
6
+ VERSION = '0.1.7'
7
7
 
8
8
  def self.version_info
9
9
  {
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tasker-rb
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.6
4
+ version: 0.1.7
5
5
  platform: x86_64-linux
6
6
  authors:
7
7
  - Pete Taylor