Account Move Template: raise UserError in case the format is not valid by keyword
Module: account
Scenario:
User run 'Create Move from Template' wizard, select a template that some keywords are not valid, and click create:
Traceback (most recent call last):
File "/tryton/trytond/trytond/protocols/dispatcher.py", line 204, in _dispatch
result = rpc.result(meth(*c_args, **c_kwargs))
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tryton/trytond/trytond/wizard/wizard.py", line 340, in execute
result = wizard._execute(state_name)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tryton/trytond/trytond/wizard/wizard.py", line 380, in _execute
result = self._execute(transition())
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tryton/trytond/trytond/wizard/wizard.py", line 375, in _execute
do_result = do(action)
^^^^^^^^^^
File "/tryton/trytond/trytond/modules/account/move_template.py", line 398, in do_open_
move = self.create_move()
^^^^^^^^^^^^^^^^^^
File "/tryton/trytond/trytond/modules/account/move_template.py", line 373, in create_move
move = template.get_move(values)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tryton/trytond/trytond/modules/account/move_template.py", line 61, in get_move
move.description = self.description.format(
^^^^^^^^^^^^^^^^^^^^^^^^
KeyError: 'descAs'
The user don't know of the reason for the traceback.
Version 6.8