Tryton Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(373)

Issue 40271002: trytond: Ensure all _parent_ values are set on fields.depends

Can't Edit
Can't Publish+Mail
Start Review
Created:
5 days, 6 hours ago by pokoli
Modified:
3 days, 22 hours ago
Reviewers:
ced, reviewbot
Visibility:
Public.

Description

If the client does not sent all the values of the parent model fields, we must ensure that the empty ones have None value issue6450

Patch Set 1 #

Total comments: 1

Patch Set 2 : Make recursive and add unittest #

Patch Set 3 : Remove uneeded join and improve test #

Total comments: 4

Patch Set 4 : Fix comments #

Total comments: 8

Patch Set 5 : Fix ced's comments #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+98 lines, -5 lines) Patch
M trytond/model/fields/field.py View 1 2 3 4 2 chunks +16 lines, -5 lines 0 comments Download
A trytond/tests/test_field_depends.py View 1 2 3 4 1 chunk +82 lines, -0 lines 1 comment Download

Messages

Total messages: 16
pokoli
5 days, 6 hours ago (2017-04-19 12:30:43 UTC) #1
reviewbot
https://codereview.tryton.org/40271002/diff/1/trytond/model/fields/field.py#newcode375 trytond/model/fields/field.py:375: E712 comparison to False should be 'if cond is False:' or 'if not ...
5 days, 6 hours ago (2017-04-19 12:32:52 UTC) #2
ced
I think it deserves its own issue. We should have unittest for this decorator. https://tryton-rietveld.appspot.com/40271002/diff/1/trytond/model/fields/field.py ...
5 days, 6 hours ago (2017-04-19 12:56:54 UTC) #3
pokoli
Make recursive and add unittest
5 days, 3 hours ago (2017-04-19 15:34:45 UTC) #4
reviewbot
https://codereview.tryton.org/40271002/diff/20001/trytond/tests/__init__.py#newcode5 trytond/tests/__init__.py:5: F403 'from test import *' used; unable to detect undefined names https://codereview.tryton.org/40271002/diff/20001/trytond/tests/__init__.py#newcode6 trytond/tests/__init__.py:6: ...
5 days, 3 hours ago (2017-04-19 15:41:21 UTC) #5
pokoli
Remove uneeded join and improve test
5 days, 3 hours ago (2017-04-19 15:41:45 UTC) #6
reviewbot
https://codereview.tryton.org/40271002/diff/20002/trytond/tests/__init__.py#newcode5 trytond/tests/__init__.py:5: F403 'from test import *' used; unable to detect undefined names https://codereview.tryton.org/40271002/diff/20002/trytond/tests/__init__.py#newcode6 trytond/tests/__init__.py:6: ...
5 days, 2 hours ago (2017-04-19 16:02:52 UTC) #7
ced
https://tryton-rietveld.appspot.com/40271002/diff/20002/trytond/model/fields/field.py File trytond/model/fields/field.py (right): https://tryton-rietveld.appspot.com/40271002/diff/20002/trytond/model/fields/field.py#newcode87 trytond/model/fields/field.py:87: def set_parent_field(record, field): is it not better name: set_value ...
5 days, 1 hour ago (2017-04-19 17:10:26 UTC) #8
pokoli
Fix comments
4 days, 4 hours ago (2017-04-20 14:02:14 UTC) #9
reviewbot
https://codereview.tryton.org/40271002/diff/50001/trytond/model/fields/field.py#newcode376 trytond/model/fields/field.py:376: E712 comparison to False should be 'if cond is False:' or 'if not ...
4 days, 4 hours ago (2017-04-20 14:38:48 UTC) #10
ced
https://tryton-rietveld.appspot.com/40271002/diff/50001/trytond/model/fields/field.py File trytond/model/fields/field.py (right): https://tryton-rietveld.appspot.com/40271002/diff/50001/trytond/model/fields/field.py#newcode87 trytond/model/fields/field.py:87: def set_value(record, field): Maybe the func could be defined ...
4 days, 3 hours ago (2017-04-20 15:35:31 UTC) #11
pokoli
Fix ced's comments
4 days, 3 hours ago (2017-04-20 15:59:32 UTC) #12
pokoli
https://tryton-rietveld.appspot.com/40271002/diff/50001/trytond/tests/test_field_depends.py File trytond/tests/test_field_depends.py (right): https://tryton-rietveld.appspot.com/40271002/diff/50001/trytond/tests/test_field_depends.py#newcode18 trytond/tests/test_field_depends.py:18: record = Model() On 2017/04/20 15:35:31, ced wrote: > ...
4 days, 3 hours ago (2017-04-20 15:59:42 UTC) #13
reviewbot
https://codereview.tryton.org/40271002/diff/70001/trytond/model/fields/field.py#newcode377 trytond/model/fields/field.py:377: E712 comparison to False should be 'if cond is False:' or 'if not ...
4 days, 2 hours ago (2017-04-20 16:01:40 UTC) #14
ced
https://tryton-rietveld.appspot.com/40271002/diff/50001/trytond/tests/test_field_depends.py File trytond/tests/test_field_depends.py (right): https://tryton-rietveld.appspot.com/40271002/diff/50001/trytond/tests/test_field_depends.py#newcode20 trytond/tests/test_field_depends.py:20: self.assertIsNone(record.name) On 2017/04/20 15:59:42, pokoli wrote: > On 2017/04/20 ...
4 days, 2 hours ago (2017-04-20 16:28:16 UTC) #15
ced
3 days, 22 hours ago (2017-04-20 20:57:52 UTC) #16
https://tryton-rietveld.appspot.com/40271002/diff/70001/trytond/tests/test_fi...
File trytond/tests/test_field_depends.py (right):

https://tryton-rietveld.appspot.com/40271002/diff/70001/trytond/tests/test_fi...
trytond/tests/test_field_depends.py:61: '_parent_parent.description',
'_parent_parent.parent',
is '_parent_parent.parent' really needed?
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld cd18842