graphql-persisted_queries 1.8.0 → 1.8.1

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: 348a66b5ed4c013fe7c41a01a752acdca8ecf2eac99f5365ac7cc11b3a6bcd4d
4
- data.tar.gz: 2c15c37b4f4f451d12ab946f86e7df67a393af8d897ec0ec718924520ea5ee7b
3
+ metadata.gz: f87195c0081c6206d4c47361e560fb3f112cbdbca6dd1135cf2e4c7716cb75c9
4
+ data.tar.gz: fe8df08ab03552a446258ff1dc68e27cb9eb810fa2e20dfa853c208a4e6676f9
5
5
  SHA512:
6
- metadata.gz: d1ec95cdd3be52b3eb1fd91eaabfffcd67642185c214272b512d0320a17e7344554ae996b0af5f43b7e9c6b69e951268ba0a34b7b0ffe850d3f0a3c38eb5d1b9
7
- data.tar.gz: 0ed5474fe161e4f4f1dfec4582f258c33217846bd9a1a607969a9f388d56740c55cb97be0f85184f30c90df56908c7dd224eac48fc7a343d83eb9c7615ea7c71
6
+ metadata.gz: 9a1d306f63ee7491d018c1716c76674effec8b55a3190244ad5843789a018297ad250e7264ee133cec26b32ada813fe28c9861133fc67e4e973bcd3312b8a810
7
+ data.tar.gz: 1cf61a5492364b85bee8a9f7d59293ba3ce5d36ae2c406f47ab6ce8aba4dc25f5a86dcd848cb1e863c4e27a693056fac49668ba2b7aa093ba26c21118ade6f89
data/CHANGELOG.md CHANGED
@@ -2,6 +2,11 @@
2
2
 
3
3
  ## master
4
4
 
5
+ ## 1.8.1 (2024-06-01)
6
+
7
+ - [PR#77](https://github.com/DmitryTsepelev/graphql-ruby-persisted_queries/pull/77)
8
+ Fix serialization of Document (broken by [this change](https://github.com/rmosolgo/graphql-ruby/commit/7de7a1f98d4299abc1fb7deb5ca0ed2190867ab6)) ([@DmitryTsepelev][])
9
+
5
10
  ## 1.8.0 (2024-03-31)
6
11
 
7
12
  - [PR#73](https://github.com/DmitryTsepelev/graphql-ruby-persisted_queries/pull/73)
@@ -7,6 +7,28 @@ module GraphQL
7
7
  class Resolver
8
8
  include GraphQL::PersistedQueries::ResolverHelpers
9
9
 
10
+ # Patch to support custom serialization
11
+ class GraphQL::Language::Parser # rubocop:disable Style/ClassAndModuleChildren
12
+ SEP = "|"
13
+
14
+ def _dump(*)
15
+ [
16
+ @graphql_str,
17
+ JSON.generate("filename": @filename, "max_tokens": @max_tokens, "document": @document)
18
+ ].join(SEP)
19
+ end
20
+
21
+ def self._load(args)
22
+ graphql_str, raw_kwargs = args.split(SEP)
23
+
24
+ new(graphql_str,
25
+ filename: raw_kwargs["filename"],
26
+ max_tokens: raw_kwargs["max_tokens"]).tap do |parser|
27
+ parser.instance_variable_set(:@document, raw_kwargs["document"])
28
+ end
29
+ end
30
+ end
31
+
10
32
  def initialize(schema, extensions)
11
33
  @schema = schema
12
34
  @extensions = extensions
@@ -2,6 +2,6 @@
2
2
 
3
3
  module GraphQL
4
4
  module PersistedQueries
5
- VERSION = "1.8.0"
5
+ VERSION = "1.8.1"
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: graphql-persisted_queries
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.8.0
4
+ version: 1.8.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - DmitryTsepelev
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-03-31 00:00:00.000000000 Z
11
+ date: 2024-06-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: graphql