Closed scorobogaci closed 1 month ago
I gave attempted to generate the output explicitly using :
- npx ampx generate outputs --branch $AWS_BRANCH --app-id $AWS_APP_ID
in the backend
build like this :
version: 1
backend:
phases:
build:
commands:
- npm ci --cache .npm --prefer-offline
- npx ampx pipeline-deploy --branch $AWS_BRANCH --app-id $AWS_APP_ID
- npx ampx generate outputs --branch $AWS_BRANCH --app-id $AWS_APP_ID
still the amplify_output.json
have not been updated
Hi @scorobogaci 👋 , thanks for reaching out. I wasn't able to reproduce this issue with the provided data schema. Can you share the following?
amplify_outputs.json
file (both the older and the latest). Since these files contain sensitive information, I'd recommend sharing this over a DM on our community discord server. My username is Jay Raval
.Hi @scorobogaci 👋 , thanks for reaching out. I wasn't able to reproduce this issue with the provided data schema. Can you share the following?
- Amplify app id
amplify_outputs.json
file (both the older and the latest). Since these files contain sensitive information, I'd recommend sharing this over a DM on our community discord server. My username isJay Raval
.- Were you trying to download the latest outputs file from the console when a deployment was is in progress?
Hello :)
No, I have downloaded the amplify_outputs.json
after the deployment was finished. I just added a new model for data, then deployed the stack (Ci triggered automatically) and after checking the output, the new model wasn't there in the amplify_outputs.json
:(
@scorobogaci can you share the information requested here? Additionally, post a deployment does the AppSync API resource get updated with the new model? Lastly, can you share your entire schema as it will be helpful for us to further investigate into this issue.
I am going to close this thread since we are unable to reproduce this issue. If you continue to experience it, feel free to create a new issue with the requested information. Thanks.
Environment information
Describe the bug
When using Amplify Gen 2 , and making some updates in
data/resource.ts
(AppSync schema), the updates on models, configurations are not reflected in amplify_output.json after the deployment succeeded. Even though the logs (deployment logs) shows[INFO]: File written: amplify_outputs.json
in fact latest changes are not written there.Funny fact, if you download the
amplify_output.json
the next day, changes are reflected ))) The most hilarious bug ever seen I guess (some async things going on)Here is the backend build in
amplify.yml
Reproduction steps
Given the following schema
Add a new model for example :
Expected is that after deployment using CI/CD Gen 2, the types and everything regarding new model should be defined and written in the
amplify_outputs.json
, while this is not happening (the file get's updated only after a day)