ISSUE: source and destination environments must have the same schema

Hello! I have created a new model on my project and tested on Developments. (im working on my forest branch new-schema). Now when i run forest deploy to view this new model on the production panel i have the error:
ISSUE: source and destination environments must have the same schema
From what I’ve been seeing I think I may need to do a push but I haven’t found the right documentation to explain how to achieve my goal. What would be the step by step guide I should do to upload these changes to production?
These changes are the creation of a new model and the addition of some fields to the existing models.

Thank you!

Hey @usr1vang,

Could you share here your project name so I can compare your schema in both your environment ?

Usually, this error indicates that the schema (.forestadmin-schema.json) running in production & in your development environment is not the same. Could you also make sure that’s the case ?

Thanks in advance

My project name is yala. Yes, there are different because i modify my schemas on development. Now i want to push this changes to production but im not sure how to do it.

The new schema should be deployed to your production first (with your code).

Once your production server restarted with the new schema, it will be send to our servers and they will be the same. Then, you should be able to apply the changes your made on the UI from development to production via forest deploy.

Im working with heroku. I have already update and restart my server but still having the same issue at the moment of forest deploy.


I’ve just compared your .forestadmin-schema.json and they are still different. Unless this is fixed on your end, forest deploy will throw this error. Both of your .forestadmin-schema.json must strictly be the same in order for the command to work.

When running your server with NODE_ENV=development, your server will regenerate this file.
When running your server with NODE_ENV=production, your server will use the existing schema and send it to our server.

I can privately share the difference I can see on the compared schema, but you should also be able to download the schema from your production server and compare it with the one you have on development.

You can also use forest schema:apply to ensure that both file are totally in sync on your environment.

I was able to do it! I was having trouble regenerating the .forestadmin-schema.json file.

Thank you very much for your time and help!