Commit ab22fc40 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

fix buildTargetSolverList().

* use tuple instead of list for a dict key.
* need to convert to dict explicitly before passing to updateConfiguration().


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@31376 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 02278466
...@@ -110,7 +110,7 @@ class SolverProcess(XMLObject, ActiveProcess): ...@@ -110,7 +110,7 @@ class SolverProcess(XMLObject, ActiveProcess):
try: try:
# Solver key contains only those properties which differentiate # Solver key contains only those properties which differentiate
# solvers (ex. there should be only Production Reduction Solver) # solvers (ex. there should be only Production Reduction Solver)
solver_key = solver.reduceConfigurationList(movement_solver_configuration_dict.keys()) solver_key = tuple(solver.reduceConfigurationList(movement_solver_configuration_dict.keys()))
except: except:
raise raise
solver_key_dict = solver_dict.setdefault(solver_type, {}) solver_key_dict = solver_dict.setdefault(solver_type, {})
...@@ -124,7 +124,8 @@ class SolverProcess(XMLObject, ActiveProcess): ...@@ -124,7 +124,8 @@ class SolverProcess(XMLObject, ActiveProcess):
solver_instance._setDeliveryList(solver_movement_dict.keys()) solver_instance._setDeliveryList(solver_movement_dict.keys())
for movement_url, configuration_list in solver_movement_dict.iteritems(): for movement_url, configuration_list in solver_movement_dict.iteritems():
for configuration_kw in configuration_list: for configuration_kw in configuration_list:
solver_instance.updateConfiguration(**configuration_kw) if len(configuration_kw):
solver_instance.updateConfiguration(**dict(configuration_kw))
# ISolver implementation # ISolver implementation
# Solver Process Workflow Interface # Solver Process Workflow Interface
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment