What does "Could not cast config to JSONValue" error mean?

0
Underlying error message: Could not cast incoming configuration to JSONValue, recoverySuggestion: Remove amplify plugins from your pubspec.yaml that you are not using in your app.,

What does this error suggest? My guess so far was the custom auth configs that I set up using amplify add auth > manual config, but nothing seems to solve this issue.

preguntada hace un año266 visualizaciones
1 Respuesta
0

When initializing Amplify, it automatically generates the files, “ amplify configuration.json, aws configuration.json” and modifies the content in the these files. The error message, “ Could not cast incoming configuration to JSONValue,” indicates that the the files mentioned, neither have a valid JSON format. Please kindly confirm that the files are in JSON format. [1]

Please kindly try:

  1. Undo any current changes by running ‘amplify env pull —restore'
  2. If you haven’t created the auth resource by pushing to the cloud yet, please do this
  3. After the ‘amplify push’ command is completed with general setup, kindly try to make custom changes to the files

References: [1] Amplify backend: https://docs.amplify.aws/start/getting-started/add-api/q/integration/react-native/

profile pictureAWS
Kary
respondido hace un año

No has iniciado sesión. Iniciar sesión para publicar una respuesta.

Una buena respuesta responde claramente a la pregunta, proporciona comentarios constructivos y fomenta el crecimiento profesional en la persona que hace la pregunta.

Pautas para responder preguntas