Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle array field types used for alias field names #4961

Merged
merged 2 commits into from
Jan 11, 2023

Conversation

gilgardosh
Copy link
Collaborator

No description provided.

@gilgardosh gilgardosh self-assigned this Jan 11, 2023
@changeset-bot
Copy link

changeset-bot bot commented Jan 11, 2023

🦋 Changeset detected

Latest commit: 158669c

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 29 packages
Name Type
@graphql-tools/utils Patch
@graphql-tools/batch-delegate Patch
@graphql-tools/batch-execute Patch
@graphql-tools/delegate Patch
@graphql-tools/executor Patch
@graphql-tools/graphql-tag-pluck Patch
@graphql-tools/import Patch
@graphql-tools/links Patch
@graphql-tools/load Patch
@graphql-tools/merge Patch
@graphql-tools/mock Patch
@graphql-tools/node-require Patch
@graphql-tools/relay-operation-optimizer Patch
@graphql-tools/resolvers-composition Patch
@graphql-tools/schema Patch
@graphql-tools/stitch Patch
@graphql-tools/stitching-directives Patch
@graphql-tools/wrap Patch
@graphql-tools/apollo-engine-loader Patch
@graphql-tools/code-file-loader Patch
@graphql-tools/git-loader Patch
@graphql-tools/github-loader Patch
@graphql-tools/graphql-file-loader Patch
@graphql-tools/json-file-loader Patch
@graphql-tools/module-loader Patch
@graphql-tools/prisma-loader Patch
@graphql-tools/url-loader Patch
graphql-tools Patch
federation-benchmark Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@gilgardosh gilgardosh added the bug label Jan 11, 2023
@github-actions
Copy link
Contributor

github-actions bot commented Jan 11, 2023

✅ Benchmark Results

     ✓ no_errors
     ✓ expected_result

     checks.........................: 100.00% ✓ 244       ✗ 0  
     data_received..................: 28 MB   2.8 MB/s
     data_sent......................: 104 kB  10 kB/s
     http_req_blocked...............: avg=4.74µs   min=2.7µs    med=3.3µs    max=162.19µs p(90)=4.1µs    p(95)=4.29µs  
     http_req_connecting............: avg=941ns    min=0s       med=0s       max=114.89µs p(90)=0s       p(95)=0s      
     http_req_duration..............: avg=77.44ms  min=67.17ms  med=73.5ms   max=181.97ms p(90)=82.68ms  p(95)=118.81ms
       { expected_response:true }...: avg=77.44ms  min=67.17ms  med=73.5ms   max=181.97ms p(90)=82.68ms  p(95)=118.81ms
     http_req_failed................: 0.00%   ✓ 0         ✗ 122
     http_req_receiving.............: avg=160.1µs  min=115.89µs med=134.69µs max=499.49µs p(90)=235.18µs p(95)=277.74µs
     http_req_sending...............: avg=174.69µs min=17µs     med=24.1µs   max=3.91ms   p(90)=39.26µs  p(95)=864.04µs
     http_req_tls_handshaking.......: avg=0s       min=0s       med=0s       max=0s       p(90)=0s       p(95)=0s      
     http_req_waiting...............: avg=77.1ms   min=67.01ms  med=73.29ms  max=181.59ms p(90)=82.22ms  p(95)=118.57ms
     http_reqs......................: 122     12.101308/s
     iteration_duration.............: avg=82.6ms   min=72ms     med=78.64ms  max=186.99ms p(90)=89.27ms  p(95)=123.42ms
     iterations.....................: 122     12.101308/s
     vus............................: 1       min=1       max=1
     vus_max........................: 1       min=1       max=1

@github-actions
Copy link
Contributor

github-actions bot commented Jan 11, 2023

🚀 Snapshot Release (alpha)

The latest changes of this PR are available as alpha on npm (based on the declared changesets):

Package Version Info
@graphql-tools/batch-delegate 8.4.15-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/batch-execute 8.5.15-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/delegate 9.0.22-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/executor 0.0.12-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/executor-apollo-link 0.0.6-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/executor-graphql-ws 0.0.6-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/executor-http 0.0.9-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/executor-legacy-ws 0.0.6-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/executor-urql-exchange 0.0.6-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/graphql-tag-pluck 7.4.3-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
graphql-tools 8.3.15-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/import 6.7.15-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/links 8.3.26-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/load 7.8.9-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/apollo-engine-loader 7.3.22-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/code-file-loader 7.3.16-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/git-loader 7.2.16-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/github-loader 7.3.23-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/graphql-file-loader 7.5.14-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/json-file-loader 7.4.15-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/module-loader 7.2.15-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/prisma-loader 7.2.51-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/url-loader 7.16.30-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/merge 8.3.15-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/mock 8.7.15-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/node-require 6.4.17-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/relay-operation-optimizer 6.5.15-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/resolvers-composition 6.5.15-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/schema 9.0.13-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/stitch 8.7.35-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/stitching-directives 2.3.25-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/utils 9.1.4-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎
@graphql-tools/wrap 9.2.24-alpha-20230111164002-30864906 npm ↗︎ unpkg ↗︎

@github-actions
Copy link
Contributor

github-actions bot commented Jan 11, 2023

🚀 Website Preview

The latest changes to the website are available as preview in: https://11531808.graphql-tools.pages.dev

@@ -476,7 +476,7 @@
const fieldPathStr = fieldPath.join('.');
let fieldName = field.name;
if (fieldTypeMap.has(fieldPathStr) && fieldTypeMap.get(fieldPathStr) !== field.type.toString()) {
fieldName += (field.type as any).toString().replace('!', 'NonNull');
fieldName += (field.type as any).toString().replace('!', 'NonNull').replace('[', 'List').replace(']', '');

Check failure

Code scanning / CodeQL

Incomplete string escaping or encoding

This replaces only the first occurrence of '\]'.
@@ -476,7 +476,7 @@
const fieldPathStr = fieldPath.join('.');
let fieldName = field.name;
if (fieldTypeMap.has(fieldPathStr) && fieldTypeMap.get(fieldPathStr) !== field.type.toString()) {
fieldName += (field.type as any).toString().replace('!', 'NonNull');
fieldName += (field.type as any).toString().replace('!', 'NonNull').replace('[', 'List').replace(']', '');

Check failure

Code scanning / CodeQL

Incomplete string escaping or encoding

This replaces only the first occurrence of '\['.
@ardatan ardatan merged commit e3ec35e into master Jan 11, 2023
@ardatan ardatan deleted the operations-field-name-fix branch January 11, 2023 19:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants