Closed adamruzicka closed 5 months ago
but I don't understand why it raises
NoMethodError: undefined method 'to_hash' for Support::DummyExample::Polling:Class
. It seemsSupport::DummyExample::Polling
isAction
, which should (?) respondto_hash
viarecursive_to_hash
(?). Obviously something gets broken on a way to serialization, but no idea when.
Apparently in https://github.com/Dynflow/dynflow/blob/master/lib/dynflow/execution_plan.rb#L287 the last self
argument is the execution plan. Because ExecutionPlan implements to_hash
, ruby 2.7 implicitly calls it as described in https://bugs.ruby-lang.org/issues/14909
Seems okay-ish?.. I mean, do we need to pass **{}
? Does it fail without this on Ruby 2.7?
I'm afraid so. In some place we explicitly need to tell ruby to not treat the previous argument as an options hash (and not call to_hash on it) :/
In the end we decided to not go down this path.
good enough to make examples/future_execution and examples/orchestrate_evented work
Let's see how many tests will be broken by this