Giter Site home page Giter Site logo

Graphql 1.13.4+ about apollo-federation-ruby HOT 6 CLOSED

Fadi25 avatar Fadi25 commented on August 30, 2024
Graphql 1.13.4+

from apollo-federation-ruby.

Comments (6)

daemonsy avatar daemonsy commented on August 30, 2024 2

Hey @Fadi25 looking at our appraisals file, we don't have support for GraphQL 1.1.3.x locked down yet. It's one of the higher priority items on my queue to look into.

Also see #147, I think that's a good place we can start.

from apollo-federation-ruby.

daemonsy avatar daemonsy commented on August 30, 2024

Done a spike on GraphQL 1.13.x support. It looks like the only real lift is to remove support from GraphQL 1.9.x, which cleans up the codebase quite a little too.

Created #161 to track this. FYI @geshwho

from apollo-federation-ruby.

daemonsy avatar daemonsy commented on August 30, 2024

Hi @Fadi25, we shipped "official support" for GraphQL 1.13.x. It's essentially just running specs against GraphQL 1.13.x.
Initially I thought we will be fixing some deprecations, but they went away with removing support for GraphQL 1.9.x.

I tried running our current specs against 1.13.4 and 1.13.5, they all passed.

Could you test if the latest version of the library works for you? If not, could you post more information to help us reproduce the problem?

from apollo-federation-ruby.

Fadi25 avatar Fadi25 commented on August 30, 2024

Thanks for the update @daemonsy,

Indeed tests are green now, however I tried updating gql to 1.13.5 and Apollo-federation 2.2.0 on my project, unfortunately I'm getting this error, for example after running mutation such as

  mutation {
    createRule(input: { threshold: 123 })
    { rule { id } }
  }

Failure/Error:
def to_graphql
field_defn = super # Returns a GraphQL::Field
field_defn.metadata[:federation_directives] = @federation_directives
field_defn
end

 ArgumentError:
   wrong number of arguments (given 1, expected 0)
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/apollo-federation-2.2.0/lib/apollo-federation/has_directives.rb:12:in `to_graphql'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/schema/object.rb:137:in `block in to_graphql'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/schema/object.rb:136:in `each'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/schema/object.rb:136:in `to_graphql'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/schema/member/accepts_definition.rb:129:in `to_graphql'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/schema/member/cached_graphql_definition.rb:52:in `to_graphql'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/apollo-federation-2.2.0/lib/apollo-federation/has_directives.rb:13:in `to_graphql'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/schema/member/cached_graphql_definition.rb:28:in `deprecated_to_graphql'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/schema/member/cached_graphql_definition.rb:21:in `graphql_definition'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/relay/global_id_resolve.rb:13:in `call'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/schema/member/has_fields.rb:109:in `block in global_id_field'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/schema/field.rb:821:in `public_send'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/schema/field.rb:821:in `block in public_send_field'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/schema/field.rb:902:in `with_extensions'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/schema/field.rb:796:in `public_send_field'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/schema/field.rb:710:in `block in resolve'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/schema.rb:118:in `after_lazy'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/schema/field.rb:708:in `resolve'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/execution/interpreter/runtime.rb:511:in `block (4 levels) in evaluate_selection_with_args'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/tracing.rb:66:in `trace'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/execution/interpreter/runtime.rb:510:in `block (3 levels) in evaluate_selection_with_args'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/query.rb:366:in `block in with_error_handling'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/execution/errors.rb:107:in `with_error_handling'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/query.rb:365:in `with_error_handling'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/execution/interpreter/runtime.rb:509:in `block (2 levels) in evaluate_selection_with_args'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/execution/interpreter/runtime.rb:797:in `resolve_with_directives'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/execution/interpreter/runtime.rb:506:in `block in evaluate_selection_with_args'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/execution/interpreter/runtime.rb:900:in `after_lazy'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/execution/interpreter/runtime.rb:440:in `evaluate_selection_with_args'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/execution/interpreter/runtime.rb:428:in `evaluate_selection'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/execution/interpreter/runtime.rb:359:in `block (2 levels) in evaluate_selections'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/dataloader.rb:181:in `block in run'
 # /Users/fadi/.rvm/gems/ruby-3.1.0/gems/graphql-1.13.5/lib/graphql/dataloader.rb:303:in `block in spawn_fiber'

from apollo-federation-ruby.

daemonsy avatar daemonsy commented on August 30, 2024

Thanks for the error report, it's very helpful. Looks like it's something that can be reproduced. I'll take a stab at it.

from apollo-federation-ruby.

daemonsy avatar daemonsy commented on August 30, 2024

Sorry for the late reply @Fadi25.

We did have an issue the missing parameter in to_graphql. It's fixed in #177 (version 2.2.1) by removing the method.

from apollo-federation-ruby.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.