Daily updates from Odoo
Tuesday, April 9, 2019
2 changes
Resolved issues and error corrections
This fix ensures that actions scheduled during a failed database savepoint are properly cleared when the savepoint is rolled back. This helps prevent unintended follow-up actions, such as email-related events, from being carried out after an error.
Original PR description
Description of the issue/feature this PR addresses:
Consider a corner case
```python
env = self.env
mail = env['mail.mail'].search(limit=1).copy()
with env.cr.savepoint():
mail.send()
raise Exception("Error!")
print(env.cr._event_handlers) # <-Notice that is not reseted
```
Current behavior before PR:
`env.cr._event_handlers` is not reset before of call `savepoint` if there is a exception during savepoint running.
Desired behavior after PR is merged:
Consider reset `env.cr._event_handlers` to original state before to call `savepoint`
cc @rco-odoo
--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-prThe home menu icon now appears correctly after refreshing a page. This prevents users from losing quick access to the main app menu during normal navigation.
Original PR description
- reference commit: https://github.com/odoo/enterprise/commit/2324786e19cb5f6e2dd5cff2afc95a5a3a05bf41 - because of this commit 'home_menu_displayed' set to false at the time of initialization. also 'on_hashchange' pass false to 'toggle_home_menu' method. so, in 'toggle_home_menu' it returns without doing anything and it does not show home menu icon. - so, set 'home_menu_displayed' to true before 'toggle_home_menu' call. Issue: https://www.odoo.com/web#id=1963354&action=327&model=project.task&view_type=form&menu_id=4720 Pad: https://pad.odoo.com/p/r.6ad6b3da67001645e1cd54f9101d2570