Hi everyone,
Am using a production environment, we override a function from core, then we pull and update in production at the very first record in any override doctype, core code works. To bypass this temporarily we reload and save at that time override works. Can you help me why it happens and how to get a permanent solution ?. Because this is the major drawback in our production environment.
Yes, until version 10, whenever we override a method in dev environment, we used to reload few times for the overridden method to get invoked instead of core. But when the code is updated in prodn environment, it used to get overridden soon after bench restart itself.
But now, in version 12, though the dev behaves the same, the production environment calls the core only, after every code change (through git or otherwise). We need to reload several times to actually get the overridden method to run. This is dangerous, as we canât have every user to reload until the override happens.
Py file invoked from hooks:
def override_PPTool(doc=None,method=None):
ProductionPlan.make_work_order = make_work_order
Trying to override make_work_order method from core, so customized and added my changes in override_PPTool method . This method is invoked while clicking âWork Orderâ from Create button refer attachment.
After updating the production environment before clicking the Work Order button we are reloading twice(manually) to override the method. if we go without reloading core method invoked.
What we understood is override happens inconsistenly!
Why is it happening like that? It makes us so hard!!!
Preferred suggestions are welcomed.
Thanks.
@perkapz is my best colleague, we didnât receive any response regarding this particular issue. so we repeatedly posted from each of our login, i dont think it has an abusement from ourside lol.