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

generate graphql-client-code generates typescript files for mobile #918

Open
nadetastic opened this issue Dec 17, 2024 · 0 comments
Open
Labels
bug Something isn't working pending-triage Issues that need further discussion to determine

Comments

@nadetastic
Copy link
Member

Environment information

System:
  OS: macOS 14.7
  CPU: (11) arm64 Apple M3 Pro
  Memory: 161.77 MB / 18.00 GB
  Shell: /bin/zsh
Binaries:
  Node: 18.20.1 - ~/.nvm/versions/node/v18.20.1/bin/node
  Yarn: 1.22.22 - ~/.nvm/versions/node/v18.20.1/bin/yarn
  npm: 10.5.0 - ~/.nvm/versions/node/v18.20.1/bin/npm
  pnpm: 9.1.2 - ~/.nvm/versions/node/v18.20.1/bin/pnpm
NPM Packages:
  @aws-amplify/auth-construct: 1.5.1
  @aws-amplify/backend: 1.9.0
  @aws-amplify/backend-auth: 1.4.2
  @aws-amplify/backend-cli: 1.4.3
  @aws-amplify/backend-data: 1.2.2
  @aws-amplify/backend-function: 1.9.0
  @aws-amplify/backend-output-schemas: 1.4.0
  @aws-amplify/backend-output-storage: 1.1.4
  @aws-amplify/backend-secret: 1.1.5
  @aws-amplify/backend-storage: 1.2.4
  @aws-amplify/cli-core: 1.2.1
  @aws-amplify/client-config: 1.5.3
  @aws-amplify/deployed-backend-client: 1.4.2
  @aws-amplify/form-generator: 1.0.3
  @aws-amplify/model-generator: 1.0.9
  @aws-amplify/platform-core: 1.3.0
  @aws-amplify/plugin-types: 1.6.0
  @aws-amplify/sandbox: 1.2.7
  @aws-amplify/schema-generator: 1.2.6
  aws-amplify: 6.10.2
  aws-cdk: 2.172.0
  aws-cdk-lib: 2.172.0
  typescript: 4.8.4
No AWS environment variables
No CDK environment variables

Describe the bug

When running npx ampx generate graphql-client-code and passing mobile specific flags for the targets, the model file is created appropriately (for swift/android) however, statement files in typescript are also generated

Reproduction steps

  1. Run mobile specific command:
    • for example in swift :npx ampx generate graphql-client-code --app-id <appid> --branch main --out swift --model-target swift
    • this generates all typescript files

image1

  1. Same command as above but adding --type-target swift
    • generates model file in swift but still generates statement files in typescript

image2

@nadetastic nadetastic added the pending-triage Issues that need further discussion to determine label Dec 17, 2024
@nadetastic nadetastic transferred this issue from aws-amplify/amplify-backend Dec 17, 2024
@phani-srikar phani-srikar added the bug Something isn't working label Jan 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working pending-triage Issues that need further discussion to determine
Projects
None yet
Development

No branches or pull requests

2 participants