graphql 2.2.2 → 2.2.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a1caad3d02e9d64f06c086fd46c324a0df1fc66c35353aef62dd716fe7ea4b9c
4
- data.tar.gz: 8c53383e4fe8b0e7d5199d42460e0a5920940ae27965a7223f5ef020b1c594cc
3
+ metadata.gz: 7177c15aedde0b99419bee77e944a4907bb84e39b5e9aafb05b2a1360903f3e6
4
+ data.tar.gz: e7252b975a41c1d8a0871e71a3fc37522741c0b872899f2f33863b76ad09934d
5
5
  SHA512:
6
- metadata.gz: ae189d6de14b18dbee6781688a43d1f15cfb1418fa9ceb45ca099f577a5cd9339c6e16d8402e7b15ba62c64afbfbaed64f3d5d64b253a51597fb50d586d5a6dd
7
- data.tar.gz: ab5860a939248086c5b8df11f0f638edce805110e75f51b068addce3e0956a9ffeda17836bf02962a943b137e4defccd48e3c18f836973f0c780c4ef225f7bd0
6
+ metadata.gz: d29b25a1186ce62664cd2225de1eac675925ebbf93ed14c6513a1008c7cd6a1b01b375a1785082ab14024ead927a073f8e3afb72ffa5905a342fcdec6a60d9fa
7
+ data.tar.gz: 6d2a445f577027d5f87a0a0ee0f0c1a562d494d7d9a5bc7209dfbb2fc5c98ce38f5fab86e7101b6537f9b9b590a2d41e1303f5dc606809683a1bde22c6bc283d
@@ -106,7 +106,7 @@ module Graphql
106
106
  end
107
107
 
108
108
  # All resolvers are defined as living in their own module, including this class.
109
- template("base_resolver.erb", "#{options[:directory]}/resolvers/base.rb")
109
+ template("base_resolver.erb", "#{options[:directory]}/resolvers/base_resolver.rb")
110
110
 
111
111
  # Note: You can't have a schema without the query type, otherwise introspection breaks
112
112
  template("query_type.erb", "#{options[:directory]}/types/query_type.rb")
@@ -1,5 +1,5 @@
1
1
  <% module_namespacing_when_supported do -%>
2
- module Types
2
+ module Resolvers
3
3
  class BaseResolver < GraphQL::Schema::Resolver
4
4
  end
5
5
  end
@@ -19,29 +19,27 @@ module GraphQL
19
19
  while first_pass || job_tasks.any?
20
20
  first_pass = false
21
21
 
22
- root_task.async do |jobs_task|
23
- while (task = job_tasks.shift || spawn_job_task(jobs_task, jobs_condition))
24
- if task.alive?
25
- next_job_tasks << task
26
- elsif task.failed?
27
- # re-raise a raised error -
28
- # this also covers errors from sources since
29
- # these jobs wait for sources as needed.
30
- task.wait
31
- end
22
+ while (task = job_tasks.shift || spawn_job_task(root_task, jobs_condition))
23
+ if task.alive?
24
+ next_job_tasks << task
25
+ elsif task.failed?
26
+ # re-raise a raised error -
27
+ # this also covers errors from sources since
28
+ # these jobs wait for sources as needed.
29
+ task.wait
32
30
  end
33
- end.wait
31
+ end
32
+ root_task.yield # give job tasks a chance to run
34
33
  job_tasks.concat(next_job_tasks)
35
34
  next_job_tasks.clear
36
35
 
37
36
  while source_tasks.any? || @source_cache.each_value.any? { |group_sources| group_sources.each_value.any?(&:pending?) }
38
- root_task.async do |sources_loop_task|
39
- while (task = source_tasks.shift || spawn_source_task(sources_loop_task, sources_condition))
40
- if task.alive?
41
- next_source_tasks << task
42
- end
37
+ while (task = source_tasks.shift || spawn_source_task(root_task, sources_condition))
38
+ if task.alive?
39
+ next_source_tasks << task
43
40
  end
44
- end.wait
41
+ end
42
+ root_task.yield # give source tasks a chance to run
45
43
  sources_condition.signal
46
44
  source_tasks.concat(next_source_tasks)
47
45
  next_source_tasks.clear
@@ -58,7 +56,7 @@ module GraphQL
58
56
  def spawn_job_task(parent_task, condition)
59
57
  if @pending_jobs.any?
60
58
  fiber_vars = get_fiber_variables
61
- parent_task.async do |t|
59
+ parent_task.async do
62
60
  set_fiber_variables(fiber_vars)
63
61
  Thread.current[:graphql_dataloader_next_tick] = condition
64
62
  while job = @pending_jobs.shift
@@ -1,4 +1,4 @@
1
1
  # frozen_string_literal: true
2
2
  module GraphQL
3
- VERSION = "2.2.2"
3
+ VERSION = "2.2.3"
4
4
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: graphql
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.2.2
4
+ version: 2.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Robert Mosolgo
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-12-27 00:00:00.000000000 Z
11
+ date: 2023-12-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: racc
@@ -631,7 +631,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
631
631
  - !ruby/object:Gem::Version
632
632
  version: '0'
633
633
  requirements: []
634
- rubygems_version: 3.4.10
634
+ rubygems_version: 3.5.3
635
635
  signing_key:
636
636
  specification_version: 4
637
637
  summary: A GraphQL language and runtime for Ruby