I have some doubts regarding the best practices for updating my Frappe version in my project. The issue arose because I’ve been developing an application on my Ubuntu system based on Frappe for several months now, and I’ve pushed my custom application to GitHub. Recently, I’ve been trying to install Frappe and pull my custom application on a remote server, encountering some problems in the process.
In my development environment, I have installed Frappe version 15.0.0, while in my server, the newly installed Frappe version is 15.12.0. In my custom app, I’ve overridden the search_link function contained in the search.py file, adding some custom logic to it. However, with the latest Frappe version installed on my server, the behavior of this function has changed, leading to an error when trying to display options in a doctype link field.
Apart from resolving the specific error, I would like to know the most straightforward way to update my Frappe version in the development server to match the version in the production server. Additionally, I’m curious about whether updating the Frappe version in the development server is the best approach for keeping the production and development environments in sync, or if it’s better to limit the Frappe version on the server to remain consistent with the development server.
In any case i would like to have a simple list of commands or steps to update my frappe version because i’m struggling with it. I apologize if this question sounds like it’s coming from a newbie, but I’m still in the learning process. Thank you all in advance for your time.
Before making any changes, create a backup of your instance. This is like taking a snapshot to ensure you can go back if anything goes wrong.
Update Version
Go to the directory where your ERPNext is installed, Then, update the version.
Test Your Custom App
We suggest you, if you want to override the base functionality then you can manage in your custom app. Please check the hook concept.
After the update, check if your custom app still works as expected. Fix any issues you find.
Save Changes to GitHub
If you’ve made changes to your custom app, commit and push them to GitHub to keep everything in sync.
Best Practices
Keep your development and production environments on the same version to avoid surprises when deploying changes.
If the new version causes issues with your custom app, consider updating your development environment first to identify and fix problems early.
It’s a good idea to test updates in a safe environment before applying them to your live site.
By following these steps and tips, you can update your Frappe and ERPNext versions while minimizing the risk of issues.