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

Parameters: [unauthRoleName] do not exist in the template #2512

Open
2 tasks done
alice-was-here opened this issue Apr 29, 2024 · 3 comments
Open
2 tasks done

Parameters: [unauthRoleName] do not exist in the template #2512

alice-was-here opened this issue Apr 29, 2024 · 3 comments
Assignees
Labels
bug Something isn't working transferred

Comments

@alice-was-here
Copy link

alice-was-here commented Apr 29, 2024

How did you install the Amplify CLI?

npm

If applicable, what version of Node.js are you using?

v18.20.2

Amplify CLI Version

12.4.0

What operating system are you using?

Ubuntu (22.04.4)

Did you make any manual changes to the cloud resources managed by Amplify? Please describe the changes made.

No manual changes made.

Describe the bug

When attempting to update the auth category of a project (when the api category has the status of No Change) the deployment fails with the following error.

Parameters: [unauthRoleName] do not exist in the template

Expected behavior

The auth category changes can be deployed, even if there has been no change to the api category.

Reproduction steps

  1. Have an Amplify project with an api and auth category, where all changes have been deployed and both categories have the status No Change

  2. Make some change to the auth config (I upgraded a lambda in the cloud formation template to run node 18 - but any change will trigger this).

  3. Run amplify push -y.

The cli will successfully begin deploying the auth changes. It will throw the unauthRoleName error when trying to deploy the api category.

Project Identifier

No response

Log output

# Put your logs below this line

UPDATE_IN_PROGRESS apiPROJECTNAME       AWS::CloudFormation::Stack Mon Apr 29 2024 08:17:27 GMT+0000 (Coordinated Universal Time)                                                          
UPDATE_FAILED      apiPROJECTNAME       AWS::CloudFormation::Stack Mon Apr 29 2024 08:17:28 GMT+0000 (Coordinated Universal Time) Parameters: [unauthRoleName] do not exist in the template

Additional information

The changes will successfully deploy IF there is any change to the api category resources. So, adding an arbitrary change to the api configuration will cause both categories to be in the status Update, and then amplify push will successfully complete for both.

Before submitting, please confirm:

  • I have done my best to include a minimal, self-contained set of instructions for consistently reproducing the issue.
  • I have removed any sensitive information from my code snippets and submission.
@alice-was-here alice-was-here changed the title Parameters: [unauthRoleName] do not exist in the template Parameters: [unauthRoleName] do not exist in the template Apr 29, 2024
@ykethan
Copy link

ykethan commented Apr 29, 2024

Hey @alice-was-here, thank you for reaching out. Could you provide us the following information.

  1. Project identifier output when running amplify diagnose --send-report
  2. Could you verify if the team-provider-info.json and amplify-meta.json contain the UnauthRoleName parameter.
  3. type of API created in the project, is this is a GraphQL API or REST API?

@alice-was-here
Copy link
Author

alice-was-here commented Apr 30, 2024

  1. Identifier: 041877376e08b4e55ad7371782ce979b
  2. Yes, both files contain the UnauthRoleName param.
  3. It is a graphql api.

@ykethan
Copy link

ykethan commented Apr 30, 2024

Hey @alice-was-here, thank you for the information. On diving into the files noticed the parameters.json under the api/<api-name>/build folder contains the following

 "authRoleName": {
    "Ref": "AuthRoleName"
  },

but the parameters.json at the api/<api-name> root folder does not contain this.
Transferring the issue to our API repository for better assistance.

@ykethan ykethan transferred this issue from aws-amplify/amplify-cli Apr 30, 2024
@ykethan ykethan added transferred and removed auth labels Apr 30, 2024
@palpatim palpatim added bug Something isn't working and removed pending-triage labels May 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working transferred
Projects
None yet
Development

No branches or pull requests

3 participants