graphiti 1.13.4 → 1.13.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yml +1 -1
- data/CHANGELOG.md +16 -0
- data/lib/graphiti/request_validators/validator.rb +6 -2
- data/lib/graphiti/resource_proxy.rb +1 -0
- data/lib/graphiti/scope.rb +1 -1
- data/lib/graphiti/version.rb +1 -1
- data/package.json +1 -0
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 50392de90dfb87c466fb106475590cc9fbea2a8d5311ff74c3808efb4bb7bd5c
|
|
4
|
+
data.tar.gz: 3fd84fb442296cd3620ca31a1528aa9dd697a57d05095d7b49a58c41b77edc3a
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 770a509901ac519c8a6a3f28147c0a191d6afedb808c0965eccfb8dcfc6fd2ceda5475bb63e04698932d0dc8dda1463eae1f2227f11db1c4296057724ab96f34
|
|
7
|
+
data.tar.gz: 1cbef5113927d195f6283a107352b27ba1f6c2adef3f23eeb2c9fdd5683af850e52c5a7b52b05fe099e99f5fce0e1c8ae79504d56f66e9c5eeb5833a364d819d
|
data/.github/workflows/ci.yml
CHANGED
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
graphiti changelog
|
|
2
2
|
|
|
3
|
+
## [1.13.6](https://github.com/graphiti-api/graphiti/compare/v1.13.5...v1.13.6) (2026-10-30)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Bug Fixes
|
|
7
|
+
|
|
8
|
+
* validate the relationships of a document wrapped in _jsonapi ([cfb624c](https://github.com/graphiti-api/graphiti/commit/cfb624c284f0ad357709ebb2297b831aa6746feb))
|
|
9
|
+
|
|
10
|
+
## [1.13.5](https://github.com/graphiti-api/graphiti/compare/v1.13.4...v1.13.5) (2026-09-04)
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
### Bug Fixes
|
|
14
|
+
|
|
15
|
+
* resolve inline when already on a sideload pool thread ([11c9de7](https://github.com/graphiti-api/graphiti/commit/11c9de7fb4bfc2d83b02aaba3e58c1f94c84cec4))
|
|
16
|
+
* scope debugger chunks to the request rather than the class ([9a77896](https://github.com/graphiti-api/graphiti/commit/9a77896c6e56d23b89d0a2aef358d8e8e0c28c54))
|
|
17
|
+
* stats[group_by] only groups by an attribute the resource reads ([cfb9b84](https://github.com/graphiti-api/graphiti/commit/cfb9b8453c5f18fd9edaefdfefdd8dab5876ce99))
|
|
18
|
+
|
|
3
19
|
## [1.13.4](https://github.com/graphiti-api/graphiti/compare/v1.13.3...v1.13.4) (2026-08-20)
|
|
4
20
|
|
|
5
21
|
|
|
@@ -16,11 +16,11 @@ module Graphiti
|
|
|
16
16
|
# Right now, all requests - even reads - go through the validator
|
|
17
17
|
# In the future these should have their own validation logic, but
|
|
18
18
|
# for now we can just bypass
|
|
19
|
-
return errors.blank? unless
|
|
19
|
+
return errors.blank? unless document.has_key?(:data)
|
|
20
20
|
|
|
21
21
|
resource = @root_resource
|
|
22
22
|
|
|
23
|
-
if
|
|
23
|
+
if document[:data].has_key?(:type)
|
|
24
24
|
if (meta_type = deserialized_payload.meta[:type].try(:to_sym))
|
|
25
25
|
if @root_resource.type != meta_type && @root_resource.polymorphic?
|
|
26
26
|
resource = @root_resource.class.resource_for_type(meta_type).new
|
|
@@ -50,6 +50,10 @@ module Graphiti
|
|
|
50
50
|
|
|
51
51
|
private
|
|
52
52
|
|
|
53
|
+
def document
|
|
54
|
+
deserialized_payload.params
|
|
55
|
+
end
|
|
56
|
+
|
|
53
57
|
def validate_page
|
|
54
58
|
page = @params[:page]
|
|
55
59
|
return if page.nil? || page.respond_to?(:each_pair)
|
|
@@ -120,6 +120,7 @@ module Graphiti
|
|
|
120
120
|
scope = @scope.unpaginated_object
|
|
121
121
|
if resource.adapter.can_group?
|
|
122
122
|
if (group = @query.hash[:stats].delete(:group_by))
|
|
123
|
+
resource.get_attr!(group[0], :readable, request: true)
|
|
123
124
|
scope = resource.adapter.group(scope, group[0])
|
|
124
125
|
end
|
|
125
126
|
end
|
data/lib/graphiti/scope.rb
CHANGED
|
@@ -156,7 +156,7 @@ module Graphiti
|
|
|
156
156
|
sideload.resolve(results, sideload_query, @resource)
|
|
157
157
|
end
|
|
158
158
|
|
|
159
|
-
# resolve_sideloads is public, and without this it would return @query.sideloads itself,
|
|
159
|
+
# resolve_sideloads is public, and without this it would return @query.sideloads itself,
|
|
160
160
|
# where a delete would silently drop that sideload from the cache key.
|
|
161
161
|
nil
|
|
162
162
|
end
|
data/lib/graphiti/version.rb
CHANGED
data/package.json
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: graphiti
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.13.
|
|
4
|
+
version: 1.13.6
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Lee Richmond
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-
|
|
11
|
+
date: 2026-10-30 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: jsonapi-serializable
|