graphql-ruby-fragment_cache icon indicating copy to clipboard operation
graphql-ruby-fragment_cache copied to clipboard

Package not working with graphql-ruby > 1.12.10

Open hectorakemp opened this issue 3 years ago • 2 comments

Issue: Getting an undefined method error for versions of GraphQL Ruby greater than v1.12.10.

undefined method `final_value' for #<GraphQL::Execution::Interpreter::Runtime:0x00007f223dddedf0>
Did you mean?  final_result
/usr/local/bundle/gems/graphql-fragment_cache-0.1.4/lib/graphql/fragment_cache/cacher.rb:13:in `call'
/usr/local/bundle/gems/graphql-fragment_cache-0.1.4/lib/graphql/fragment_cache/instrumentation.rb:17:in `after_query'

I fixed this by downgrading to v1.12.10. Maybe this method got renamed to final_result in the later versions? See API docs here: https://graphql-ruby.org/api-doc/1.12.10/GraphQL/Execution/Interpreter/Runtime.html#final_value-instance_method vs https://graphql-ruby.org/api-doc/1.12.14/GraphQL/Execution/Interpreter/Runtime.html#final_result-instance_method

Love the package otherwise. Keep up the great work :pray:

hectorakemp avatar Sep 06 '21 04:09 hectorakemp

Hi @hectorakemp!

As I see, you use 0.1.4, please try to upgrade the gem to (at least) 0.1.6, we stopped using final_value at that point. Let me know if it helps 🙂

DmitryTsepelev avatar Sep 06 '21 12:09 DmitryTsepelev

Thanks for taking the time to respond @DmitryTsepelev. Will upgrade my package promptly.

hectorakemp avatar Sep 06 '21 13:09 hectorakemp