Skip to content

Conversation

@jeffschoner
Copy link
Contributor

Summary

This is a more refined fix for being able to invoke a workflow by name (#123, originally fixed in #128) that also allows workflows using Sorbet to be declared final (fixing #178). The object is now only dup'd before calling .singleton_class if it's a String.

Testing

Existing tests for starting workflows continue to pass (as do all other tests):

bundle exec rspec spec/integration/start_workflow_spec.rb

I've also tested that,

  • All specs (both unit and integration) pass on protobuf 3.19.1 with grpc 1.41.1. The underlying issue in protobuf for invoking by name was fixed in 3.20.0.
  • A simple workflow whose class and execute method are marked as final works without a runtime error. A test for this cannot be checked in without taking a new dependency on the Sorbet runtime. Code that I used to test this can be found at https://gist.github.com/jeffschoner/588ffec227506de7a8cd23d71889c42e

@DeRauk DeRauk merged commit ed2e905 into coinbase:master Feb 27, 2023
@jeffschoner jeffschoner deleted the sorbet-final branch April 21, 2023 17:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants