apollographql / apollographql/apollo-tooling

swift codegen - fragments not included in queries in operation IDs JSON

Open
#1,430 0 comments 1 reaction 0 assignees View on GitHub
Dominant language
TypeScript
Stars
3k
Forks
460
PR merge metrics
No merged PRs in 30d

Description

**Intended outcome:**

When generating a manifest of operation IDs / queries via the `--operationIdsPath` option, the JSON file should include fragment definitions.

**Actual outcome:**

Fragment definitions are missing from the queries.

**How to reproduce the issue:**

See repo here (codegen command used is in `package.json`): https://github.com/darrenclark/apollo-operation-ids-issue

Diff with a fixed copy of the JSON file: https://github.com/darrenclark/apollo-operation-ids-issue/compare/fixed

**Versions**

2.16

Contributor guide

Open the contributing guide

Research direction

Start with the codegen command in the linked reproduction's package.json and inspect the --operationIdsPath output, using the linked fixed JSON diff as the expected result. Trace how fragment definitions are collected for Swift codegen; done means the generated operation-IDs JSON includes the required fragment definitions in its queries.

Written by the indexing model from the issue text.

Assessment

Tech stack
swift, typescript
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.