odoo/odoo#196709
Created by fw-bot
Statuses:
- legal/cla: Contributor License Agreement check
- ci/runbot: Odoo Test Suite
- ci/upgrade_enterprise: Test upgrades for enterprise master
- ci/style: Optional style check. Ignore it only if strictly necessary.
- ci/security: Required security check. Can only be ignored by security team.
- label
- odoo-dev:master-saas-18.1-sentry-6250719075-typeerror-mrp-production-overview-alsh-414155-fw
- head
- 07727fa29da878d064bbca10de79b0675eb47c3c
- merged
- 8 months ago by Bugfix, Altaf Shaik (alsh)
odoo/odoo | |
---|---|
saas-18.1 | #196566 |
saas-18.2 | |
saas-18.3 | |
saas-18.4 | |
19.0 | |
master | #196709 |
[FW][FIX] mrp: fix traceback when clicking overview of a MO
Currently, a traceback appears when the user opens 'Overview' of a canceled 'Manufacturing Order'.
To reproduce this issue:
1) Install MRP
2) Create a new Manufacturing Order record
3) Give a product
with a Quantity
more than the On hand
quantity of that product
4) Add a product in the Component with the To consume
value more than
the On Hand quantity of that product
5) Click on the Cancel
button then Click the Overview
button
Error:-
TypeError: can't compare datetime.datetime to datetime.date
This error is occurring because of the recent changes from the below.
#184928/files#diff-a889e57d7462d595b2a3e056dc37237c9ab73d43c42458b52288733ae84aca73L609-R609
Initially, it was datetime.datetime
, But recently it was changed to the datetime.date
.
This leads to the above traceback when a comparison is made between
datetime.datetime
and datetime.date
from the below lines
https://github.com/odoo/odoo/blob/cb96e9133590e07880f0e98b21486d578caecd3a/addons/mrp/report/mrp_report_mo_overview.py#L583
sentry-6250719075
Forward-Port-Of: #196566