skip to Main Content

I have a form where some values are taken and at the end some images are added through expo image picker. All of those informations are to be uploaded to AWS amplify so upon importing the models I suddenly receive a weird error I haven’t seen before and it says
enter image description here

The moment I comment the line where I import the model it doesn’t show that error but then I can’t upload to AWS.

import { DataStore } from "@aws-amplify/datastore";
import { House } from "../models";

2

Answers


  1. Chosen as BEST ANSWER

    The problem was coming from Codegen version being outdated I guess so running amplify upgrade then amplify codegen models upgraded the CLI and updated the codegen version therefore solving the issue


  2. I was on Amplify CLI version 6.3.1 and amplify upgrade had no effect.
    A simple reinstall did the trick: https://docs.amplify.aws/cli/start/install/

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search