Discussion:
[Erp5-dev] Production (MRP) problems
Łukasz K. Nowak
2007-05-25 08:49:25 UTC
Permalink
Hello,

It is not possible to confirm production orders anymore. I'm attaching
patch for testProductionOrder to prove it.

I've also written on erp5-users[1] about this issue.

Luke

[1]http://thread.gmane.org/gmane.comp.python.zope.erp5.general/688/focus=708
--
?ukasz Nowak R&D Ventis http://www.ventis.com.pl/
tel: +48 32 768 16 85 fax: +48 32 392 10 61
``Use the Source, Luke...''

-------------- next part --------------
A non-text attachment was scrubbed...
Name: testProductionOrder-with-order-confirmation.patch
Type: text/x-patch
Size: 1346 bytes
Desc: not available
URL: <http://mail.tiolive.com/pipermail/erp5-dev/attachments/20070525/4175d091/attachment.bin>
Jérôme Perrin
2007-05-25 09:50:45 UTC
Permalink
Post by Łukasz K. Nowak
Hello,
It is not possible to confirm production orders anymore. I'm attaching
patch for testProductionOrder to prove it.
I've also written on erp5-users[1] about this issue.
Ah, I know this bug, catalog tool now automatically converts dicts passed as
keyword arguments to a Query, and it fails if it cannot be converted to
Query. Before, dicts were simply ignored if the keyword argument was not a
valid key (related key or catalog column).
IIRC this script receives the activity_kw dict in **kw, and pass it to
portal_catalog.

J?rome
Łukasz K. Nowak
2007-05-25 11:11:37 UTC
Permalink
Hello,
Post by Jérôme Perrin
Ah, I know this bug, catalog tool now automatically converts dicts passed as
keyword arguments to a Query, and it fails if it cannot be converted to
Query. Before, dicts were simply ignored if the keyword argument was not a
valid key (related key or catalog column).
IIRC this script receives the activity_kw dict in **kw, and pass it to
portal_catalog.
Well. I'd like to help, but only what I can provide is test, which is
doing exactly whats described in HowToMinimalProductionScenario[1].

It is passing on our archaic 10526 revision.

Luke

[1]http://www.erp5.org/HowToMinimalProductionScenario
--
?ukasz Nowak R&D Ventis http://www.ventis.com.pl/
tel: +48 32 768 16 85 fax: +48 32 392 10 61
``Use the Source, Luke...''

-------------- next part --------------
A non-text attachment was scrubbed...
Name: testMinimalProductionScenario.py
Type: text/x-python
Size: 7928 bytes
Desc: not available
URL: <http://mail.tiolive.com/pipermail/erp5-dev/attachments/20070525/911a4da4/attachment.py>
Jérôme Perrin
2007-05-28 15:07:01 UTC
Permalink
Post by Łukasz K. Nowak
Hello,
Post by Jérôme Perrin
Ah, I know this bug, catalog tool now automatically converts dicts passed
as keyword arguments to a Query, and it fails if it cannot be converted
to Query. Before, dicts were simply ignored if the keyword argument was
not a valid key (related key or catalog column).
IIRC this script receives the activity_kw dict in **kw, and pass it to
portal_catalog.
Well. I'd like to help, but only what I can provide is test, which is
doing exactly whats described in HowToMinimalProductionScenario[1].
It is passing on our archaic 10526 revision.
Thanks,

If it can help you, I checked in the quick workaround I made for erp5_payroll
on our instance is http://svn.erp5.org?rev=14636&view=rev

The problem is that all keywords arguments passed to DeliveryBuilder.build are
passed to the "select movement list" script. The workflow script passes
explanation_uid, so I hardcoded explanation_uid here :/. IMHO we should
restore "ignore unknown keys" behaviour on catalog, and pass **kw.

J?rome
Łukasz Nowak
2007-07-13 11:01:09 UTC
Permalink
Hello,

On 2007-05-28, 17:07:01
Post by Jérôme Perrin
If it can help you, I checked in the quick workaround I made for
erp5_payroll on our instance is
http://svn.erp5.org?rev=14636&view=rev
The problem is that all keywords arguments passed to
DeliveryBuilder.build are passed to the "select movement list"
script. The workflow script passes explanation_uid, so I hardcoded
explanation_uid here :/. IMHO we should restore "ignore unknown keys"
behaviour on catalog, and pass **kw.
Ok - understood a little and I was able to create patch for production
packing list and report builders - attached. I've patched issue with
ProductionOrder_zSelectMovement which returns not only Simulation
Movement - sorry, I'm not able (for now...) to patch
ProductionOrder_zSelectMovement to return only Simulation Movement, so
I've patched test function in builder to check object's portal_type.

Also patch to testProductionOrder.py which checks if system is able to
build production packing list and reports attached.

I'd be glad if that patches would be commited.

Thanks,
Luke
--
?ukasz Nowak R&D Ventis http://www.ventis.com.pl/
tel: +48 32 768 16 85 fax: +48 32 392 10 61
``Use the Source, Luke...''
-------------- next part --------------
A non-text attachment was scrubbed...
Name: testProductionOrder.py-checks-we-are-able-to-build-production-packing-list-and-reports.patch
Type: text/x-patch
Size: 1117 bytes
Desc: not available
URL: <http://mail.tiolive.com/pipermail/erp5-dev/attachments/20070713/6210d906/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: TransformationRule_selectMovement.kw_and_test.patch
Type: text/x-patch
Size: 1143 bytes
Desc: not available
URL: <http://mail.tiolive.com/pipermail/erp5-dev/attachments/20070713/6210d906/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: TransformationSourcingRule_selectMovement.kw_and_test.patch
Type: text/x-patch
Size: 1486 bytes
Desc: not available
URL: <http://mail.tiolive.com/pipermail/erp5-dev/attachments/20070713/6210d906/attachment-0002.bin>
Romain Courteaud
2007-07-17 14:24:41 UTC
Permalink
Post by Łukasz Nowak
I'd be glad if that patches would be commited.
Checked and commited.

Regards,
Romain

Loading...