Add support for python3.8
When I open the list of products on a sale line I'm getting the following exception:
Traceback (most recent call last):
File "/site-packages/trytond-5.4.1-py3.8.egg/trytond/wsgi.py", line 108, in dispatch_request
return endpoint(request, **request.view_args)
File "/site-packages/trytond-5.4.1-py3.8.egg/trytond/protocols/dispatcher.py", line 47, in rpc
return methods.get(request.rpc_method, _dispatch)(
File "/site-packages/trytond-5.4.1-py3.8.egg/trytond/wsgi.py", line 76, in auth_required
return wrapped(*args, **kwargs)
File "/site-packages/trytond-5.4.1-py3.8.egg/trytond/protocols/wrappers.py", line 131, in wrapper
return func(request, pool, *args, **kwargs)
File "/site-packages/trytond-5.4.1-py3.8.egg/trytond/protocols/dispatcher.py", line 186, in _dispatch
result = rpc.result(meth(*c_args, **c_kwargs))
File "/site-packages/trytond-5.4.1-py3.8.egg/trytond/model/modelsql.py", line 836, in read
getter_results = field.get(ids, cls, field_list, values=result)
File "/site-packages/trytond-5.4.1-py3.8.egg/trytond/model/fields/function.py", line 106, in get
return dict((name, call(name)) for name in names)
File "/site-packages/trytond-5.4.1-py3.8.egg/trytond/model/fields/function.py", line 106, in <genexpr>
return dict((name, call(name)) for name in names)
File "/site-packages/trytond-5.4.1-py3.8.egg/trytond/model/fields/function.py", line 99, in call
return method(records, name)
File "/product.py", line 162, in get_quantity
return super(Product, cls).get_quantity(products, name)
File "/site-packages/trytond_stock-5.4.0-py3.8.egg/trytond/modules/stock/product.py", line 129, in get_quantity
return cls._get_quantity(
File "/site-packages/trytond_stock-5.4.0-py3.8.egg/trytond/modules/stock/move.py", line 94, in _get_quantity
pbl = Product.products_by_location(
File "/site-packages/trytond_stock-5.4.0-py3.8.egg/trytond/modules/stock/product.py", line 206, in products_by_location
for key in quantities:
RuntimeError: dictionary keys changed during iteration
Fault: dictionary keys changed during iteration
This error only happens since I've updated to python3.8