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

fix: @defer directive is duplicated when schema already has one #235

Merged
merged 4 commits into from Jan 11, 2024

Conversation

calvincestari
Copy link
Member

@calvincestari calvincestari commented Jan 10, 2024

This is a quick-fix for users on the router with a schema that supports defer.

The defer code merged into main manually adds the @defer directive to the schema because it is still an experimental spec directive. This is causing a duplicate directive error and is blocking codegen.

All the Swift codegen tests for defer as being skipped now. This is OK-ish because defer is disabled in the JS frontend anyways so nobody can actually generate deferred operation models from main. This will be reverted in the feature/defer-execution-networking branch.

@calvincestari calvincestari requested a review from a team as a code owner January 10, 2024 23:33
Copy link

netlify bot commented Jan 10, 2024

Deploy Preview for eclectic-pie-88a2ba canceled.

Name Link
🔨 Latest commit a1b2762
🔍 Latest deploy log https://app.netlify.com/sites/eclectic-pie-88a2ba/deploys/659f34a59d562d0009a94842

Copy link
Contributor

@AnthonyMDev AnthonyMDev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would think that using throw XCTSkip would cause the tests to show an error, but I guess the skip error is handled properly by XCTest? So if all the tests are passing, this LGTM.

@calvincestari calvincestari merged commit fb72fae into main Jan 11, 2024
19 checks passed
@calvincestari calvincestari deleted the fix/duplicate-defer-directive branch January 11, 2024 01:15
BobaFetters pushed a commit to apollographql/apollo-ios-codegen that referenced this pull request Jan 11, 2024
BobaFetters pushed a commit that referenced this pull request Jan 11, 2024
c7b03c2b fix:  directive is duplicated when schema already has one (#235)

git-subtree-dir: apollo-ios-codegen
git-subtree-split: c7b03c2ba5bd70974189ee8d7e699cbe10eefdc7
BobaFetters pushed a commit that referenced this pull request Jan 11, 2024
…en schema already has one

git-subtree-dir: apollo-ios-codegen
git-subtree-mainline: ec6f3b0
git-subtree-split: c7b03c2ba5bd70974189ee8d7e699cbe10eefdc7
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants