github-community-projects / graphql-client

A Ruby library for declaring, composing and executing GraphQL queries
MIT License
42 stars 218 forks source link

Address the deprecation warnings from the logger #10

Closed yuki24 closed 8 months ago

yuki24 commented 8 months ago

This PR https://github.com/rails/rails/pull/45976 has deprecated the optional argument for the color method in the Active Support:: LogSubscriber, and the graphql-client gem depends on the deprecated interface in the lib/graphql/client/log_subscriber.rb. As a result, the following deprecation warning would appear when used with Rails 7.1.

DEPRECATION WARNING: Bolding log text with a positional boolean is deprecated and will be removed in Rails 7.2. Use an option hash instead (eg. ).

This PR updates the code to be compatible with both the latest rails and the older ones.

cc @erikdstock @jonallured

rmosolgo commented 8 months ago

Thanks for this fix!