question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[BUG] bench update with Customisation and Patch

See original GitHub issue

During bench update the following workflow is run:

  1. Update repos
  2. Run Patches
  3. Migrate Apps
  4. Build JS and HTML changes
  5. Restart Bench

In this workflow, a particular use case is failing. In the event that we need to add a new field through customisation and at the same time create a Patch to set values to this new field for old data, the update fails. This is because the Patch is run before the new field is created on migrate.

Should we consider to edit the update workflow? Or there is a proper way to deal with this usecase?

Note: Quick fix is to separate the Patch and do update first for customisation to take effect and add the patch later on. But this is not practical at all times.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
rmehtacommented, Oct 31, 2018

Run frappe.reload_doctype explicitly before running your patch code.

0reactions
rmehtacommented, Aug 8, 2018

This feature does not exist, you will have to write it!

On 08-Aug-2018, at 9:35 AM, Doridel Cahanap notifications@github.com wrote:

@rmehta https://github.com/rmehta do you have any example of a patch that is run after update somewhere so we could take a look?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/frappe/frappe/issues/5824#issuecomment-411277880, or mute the thread https://github.com/notifications/unsubscribe-auth/AAIjLLDpWMg9D2szj1Ll02jwVx0IkAdlks5uOmOUgaJpZM4VQnzl.

Read more comments on GitHub >

github_iconTop Results From Across the Web

V10.x.x custom app error on bench update --patch
We have a custom application that worked before. When bench update --patch I get an error message with a JSON problem.
Read more >
Bench Commands - Frappe Framework
update : If executed in a bench directory, without any flags will backup, pull, setup requirements, build, run patches and restart bench. Using...
Read more >
PC Building Simulator 2 | Update v1.00.14
Today we're pushing an update live, bringing us to patch v1.00.14. In this version we've addressed a number of priority issues listed below, ......
Read more >
git-bisect Documentation - Git
This command uses a binary search algorithm to find which commit in your project's history introduced a bug. You use it by first...
Read more >
NHL® 23 Patch Notes - Nov 8th - EA Sports
Presentation · Fixed an issue with an end-of-game celebration which showed players that were sitting on the bench celebrating with goalie instead ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found