rack-graphql 3.3.0 → 3.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.bundler-version +1 -1
- data/.dependabot/config.yml +9 -13
- data/.github/workflows/auto-approve.yml +1 -1
- data/.github/workflows/auto-merge.yml +1 -1
- data/.github/workflows/ci.yml +2 -2
- data/CHANGELOG.md +7 -0
- data/Gemfile.lock +39 -33
- data/lib/rack_graphql/middleware.rb +8 -6
- data/lib/rack_graphql/version.rb +1 -1
- data/rack-graphql.gemspec +1 -1
- metadata +4 -5
- data/.github/workflows/auto-merge-dependencies.yml +0 -24
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c46f2f63b1726129a28420ce5f39cfb2f18506211f84ae943754538cc6d1f118
|
4
|
+
data.tar.gz: 37b047710445593ba3d227e3db9a4e2ab2827215a8cffaa0c2b261e76cc0b603
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 011405a88de241e90a2eb6e1408c998dd17898c28519fa963495ae4d824b61cfe536e89d11c610a6b4eeafb455b20d0e2f985af18c7802f3729e6a1047479f54
|
7
|
+
data.tar.gz: 40bfbc8a432baa9d22b13b88cc4262d33c36043a245060d71ca879b34c2e9a7731d65b5afd77787445534636fa7f3407cecb7c465e230a7f877b408745dc1b80
|
data/.bundler-version
CHANGED
@@ -1 +1 @@
|
|
1
|
-
2.
|
1
|
+
2.5.9
|
data/.dependabot/config.yml
CHANGED
@@ -1,19 +1,15 @@
|
|
1
|
-
version:
|
1
|
+
version: 2
|
2
2
|
|
3
|
-
|
4
|
-
-
|
3
|
+
updates:
|
4
|
+
- package-ecosystem: "bundler"
|
5
5
|
directory: "/"
|
6
|
-
|
7
|
-
|
6
|
+
schedule:
|
7
|
+
interval: "weekly"
|
8
|
+
day: "monday"
|
9
|
+
time: "08:00"
|
10
|
+
timezone: "UTC"
|
11
|
+
commit-message:
|
8
12
|
prefix: "[dependabot]"
|
9
|
-
allowed_updates:
|
10
|
-
- match:
|
11
|
-
dependency_type: "all"
|
12
|
-
update_type: "security"
|
13
|
-
automerged_updates:
|
14
|
-
- match:
|
15
|
-
dependency_type: "all"
|
16
|
-
update_type: "security:patch"
|
17
13
|
labels:
|
18
14
|
- "automerge"
|
19
15
|
- "dependencies"
|
@@ -8,6 +8,6 @@ jobs:
|
|
8
8
|
runs-on: ubuntu-latest
|
9
9
|
steps:
|
10
10
|
- uses: hmarr/auto-approve-action@v3
|
11
|
-
if: github.actor == 'dependabot[bot]' || github.actor == 'dependabot-preview[bot]' || github.actor == 'renofidev' || contains(
|
11
|
+
if: github.actor == 'dependabot[bot]' || github.actor == 'dependabot-preview[bot]' || github.actor == 'renofidev' || contains(github.event.pull_request.labels.*.name, 'HOTFIX-AUTO-APPROVE') || contains(github.event.pull_request.labels.*.name, 'dependencies')
|
12
12
|
with:
|
13
13
|
github-token: "${{ secrets.GITHUB_TOKEN }}"
|
data/.github/workflows/ci.yml
CHANGED
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,12 @@
|
|
1
1
|
# CHANGELOG
|
2
2
|
|
3
|
+
## 3.6.0 - 2024-04-26
|
4
|
+
- drop ruby 3.1 support
|
5
|
+
- pass context.headers to the http reponse
|
6
|
+
|
7
|
+
## 3.5.0 - 2024-02-29
|
8
|
+
- make ruby 3.1 as a minimum ruby version, add ruby 3.3 support
|
9
|
+
|
3
10
|
## 3.3.0 - 2023-11-23
|
4
11
|
|
5
12
|
- add `request_epilogue` so actions like `ActiveRecord::Base.connection_handler.clear_active_connections!` can be passed manually
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
rack-graphql (3.
|
4
|
+
rack-graphql (3.6.0)
|
5
5
|
graphql (~> 2.0)
|
6
6
|
oj
|
7
7
|
rack (>= 2.2.6)
|
@@ -11,65 +11,71 @@ GEM
|
|
11
11
|
specs:
|
12
12
|
ast (2.4.2)
|
13
13
|
awesome_print (1.9.2)
|
14
|
+
base64 (0.2.0)
|
15
|
+
bigdecimal (3.1.7)
|
14
16
|
coderay (1.1.3)
|
15
|
-
diff-lcs (1.5.
|
16
|
-
graphql (2.1
|
17
|
-
|
18
|
-
json (2.
|
17
|
+
diff-lcs (1.5.1)
|
18
|
+
graphql (2.3.1)
|
19
|
+
base64
|
20
|
+
json (2.7.2)
|
19
21
|
language_server-protocol (3.17.0.3)
|
20
|
-
method_source (1.
|
21
|
-
oj (3.16.
|
22
|
-
|
23
|
-
|
22
|
+
method_source (1.1.0)
|
23
|
+
oj (3.16.3)
|
24
|
+
bigdecimal (>= 3.0)
|
25
|
+
parallel (1.24.0)
|
26
|
+
parser (3.3.0.5)
|
24
27
|
ast (~> 2.4.1)
|
25
28
|
racc
|
26
29
|
pry (0.14.2)
|
27
30
|
coderay (~> 1.1)
|
28
31
|
method_source (~> 1.0)
|
29
32
|
racc (1.7.3)
|
30
|
-
rack (3.0.
|
33
|
+
rack (3.0.10)
|
31
34
|
rack-test (2.1.0)
|
32
35
|
rack (>= 1.3)
|
33
36
|
rainbow (3.1.1)
|
34
|
-
rake (13.1
|
35
|
-
regexp_parser (2.
|
37
|
+
rake (13.2.1)
|
38
|
+
regexp_parser (2.9.0)
|
36
39
|
rexml (3.2.6)
|
37
|
-
rspec (3.
|
38
|
-
rspec-core (~> 3.
|
39
|
-
rspec-expectations (~> 3.
|
40
|
-
rspec-mocks (~> 3.
|
41
|
-
rspec-core (3.
|
42
|
-
rspec-support (~> 3.
|
43
|
-
rspec-expectations (3.
|
40
|
+
rspec (3.13.0)
|
41
|
+
rspec-core (~> 3.13.0)
|
42
|
+
rspec-expectations (~> 3.13.0)
|
43
|
+
rspec-mocks (~> 3.13.0)
|
44
|
+
rspec-core (3.13.0)
|
45
|
+
rspec-support (~> 3.13.0)
|
46
|
+
rspec-expectations (3.13.0)
|
44
47
|
diff-lcs (>= 1.2.0, < 2.0)
|
45
|
-
rspec-support (~> 3.
|
46
|
-
rspec-mocks (3.
|
48
|
+
rspec-support (~> 3.13.0)
|
49
|
+
rspec-mocks (3.13.0)
|
47
50
|
diff-lcs (>= 1.2.0, < 2.0)
|
48
|
-
rspec-support (~> 3.
|
49
|
-
rspec-support (3.
|
50
|
-
rubocop (1.
|
51
|
+
rspec-support (~> 3.13.0)
|
52
|
+
rspec-support (3.13.1)
|
53
|
+
rubocop (1.63.3)
|
51
54
|
json (~> 2.3)
|
52
55
|
language_server-protocol (>= 3.17.0)
|
53
56
|
parallel (~> 1.10)
|
54
|
-
parser (>= 3.
|
57
|
+
parser (>= 3.3.0.2)
|
55
58
|
rainbow (>= 2.2.2, < 4.0)
|
56
59
|
regexp_parser (>= 1.8, < 3.0)
|
57
60
|
rexml (>= 3.2.5, < 4.0)
|
58
|
-
rubocop-ast (>= 1.
|
61
|
+
rubocop-ast (>= 1.31.1, < 2.0)
|
59
62
|
ruby-progressbar (~> 1.7)
|
60
63
|
unicode-display_width (>= 2.4.0, < 3.0)
|
61
|
-
rubocop-ast (1.
|
62
|
-
parser (>= 3.
|
63
|
-
rubocop-capybara (2.
|
64
|
+
rubocop-ast (1.31.2)
|
65
|
+
parser (>= 3.3.0.4)
|
66
|
+
rubocop-capybara (2.20.0)
|
67
|
+
rubocop (~> 1.41)
|
68
|
+
rubocop-factory_bot (2.25.1)
|
64
69
|
rubocop (~> 1.41)
|
65
|
-
rubocop-factory_bot (2.24.0)
|
66
|
-
rubocop (~> 1.33)
|
67
70
|
rubocop-rake (0.6.0)
|
68
71
|
rubocop (~> 1.0)
|
69
|
-
rubocop-rspec (2.
|
72
|
+
rubocop-rspec (2.29.1)
|
70
73
|
rubocop (~> 1.40)
|
71
74
|
rubocop-capybara (~> 2.17)
|
72
75
|
rubocop-factory_bot (~> 2.22)
|
76
|
+
rubocop-rspec_rails (~> 2.28)
|
77
|
+
rubocop-rspec_rails (2.28.3)
|
78
|
+
rubocop (~> 1.40)
|
73
79
|
ruby-progressbar (1.13.0)
|
74
80
|
unicode-display_width (2.5.0)
|
75
81
|
|
@@ -95,4 +101,4 @@ DEPENDENCIES
|
|
95
101
|
rubocop-rspec
|
96
102
|
|
97
103
|
BUNDLED WITH
|
98
|
-
2.
|
104
|
+
2.5.9
|
@@ -149,13 +149,15 @@ module RackGraphql
|
|
149
149
|
end
|
150
150
|
|
151
151
|
def response_headers(result = nil, status_code: DEFAULT_STATUS_CODE)
|
152
|
-
{
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
headers[SUBSCRIPTION_ID_HEADER_NAME] = result.context[:subscription_id] if result_subscription?(result)
|
152
|
+
headers = { STATUS_CODE_HEADER_NAME => status_code }
|
153
|
+
headers[SUBSCRIPTION_ID_HEADER_NAME] = result.context[:subscription_id] if result_subscription?(result)
|
154
|
+
result_collection = result.is_a?(Array) ? result : [result]
|
155
|
+
result_collection.each do |part|
|
156
|
+
headers.merge!(part.context[:headers]) if part.context[:headers].is_a?(Hash)
|
158
157
|
end
|
158
|
+
headers["Access-Control-Expose-Headers"] = [SUBSCRIPTION_ID_HEADER_NAME, STATUS_CODE_HEADER_NAME].join(", ")
|
159
|
+
headers["Content-Type"] = "application/json"
|
160
|
+
headers
|
159
161
|
end
|
160
162
|
|
161
163
|
def response_status(result)
|
data/lib/rack_graphql/version.rb
CHANGED
data/rack-graphql.gemspec
CHANGED
@@ -24,7 +24,7 @@ Gem::Specification.new do |spec|
|
|
24
24
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
25
25
|
spec.require_paths = ['lib']
|
26
26
|
|
27
|
-
spec.required_ruby_version = '>= 3.
|
27
|
+
spec.required_ruby_version = Gem::Requirement.new('>= 3.2.0')
|
28
28
|
|
29
29
|
spec.add_dependency 'graphql', '~> 2.0'
|
30
30
|
spec.add_dependency 'oj'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rack-graphql
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.
|
4
|
+
version: 3.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Krzysztof Knapik
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-04-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: graphql
|
@@ -66,7 +66,6 @@ files:
|
|
66
66
|
- ".github/ISSUE_TEMPLATE/story.md"
|
67
67
|
- ".github/PULL_REQUEST_TEMPLATE.md"
|
68
68
|
- ".github/workflows/auto-approve.yml"
|
69
|
-
- ".github/workflows/auto-merge-dependencies.yml"
|
70
69
|
- ".github/workflows/auto-merge.yml"
|
71
70
|
- ".github/workflows/ci.yml"
|
72
71
|
- ".gitignore"
|
@@ -101,14 +100,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
101
100
|
requirements:
|
102
101
|
- - ">="
|
103
102
|
- !ruby/object:Gem::Version
|
104
|
-
version:
|
103
|
+
version: 3.2.0
|
105
104
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
106
105
|
requirements:
|
107
106
|
- - ">="
|
108
107
|
- !ruby/object:Gem::Version
|
109
108
|
version: '0'
|
110
109
|
requirements: []
|
111
|
-
rubygems_version: 3.
|
110
|
+
rubygems_version: 3.5.9
|
112
111
|
signing_key:
|
113
112
|
specification_version: 4
|
114
113
|
summary: Rack middleware implementing graphql endpoint.
|
@@ -1,24 +0,0 @@
|
|
1
|
-
name: automerge-dependencies
|
2
|
-
on:
|
3
|
-
pull_request_review:
|
4
|
-
types:
|
5
|
-
- submitted
|
6
|
-
check_suite:
|
7
|
-
types:
|
8
|
-
- completed
|
9
|
-
label:
|
10
|
-
types:
|
11
|
-
- created
|
12
|
-
status: {}
|
13
|
-
jobs:
|
14
|
-
automerge:
|
15
|
-
runs-on: ubuntu-latest
|
16
|
-
steps:
|
17
|
-
- name: automerge-dependencies
|
18
|
-
uses: pascalgn/automerge-action@v0.15.6
|
19
|
-
env:
|
20
|
-
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
|
21
|
-
MERGE_METHOD: squash
|
22
|
-
MERGE_DELETE_BRANCH: true
|
23
|
-
MERGE_LABELS: dependencies
|
24
|
-
MERGE_REMOVE_LABELS: ""
|