Traceback (most recent call last):
File "/trytond/wsgi.py", line 71, in dispatch_request
return endpoint(request, **request.view_args)
File "/trytond/protocols/dispatcher.py", line 41, in rpc
request, database_name, *request.rpc_params)
File "/trytond/wsgi.py", line 42, in auth_required
return wrapped(*args, **kwargs)
File "/trytond/protocols/wrappers.py", line 122, in wrapper
return func(request, pool, *args, **kwargs)
File "/trytond/protocols/dispatcher.py", line 172, in _dispatch
result = rpc.result(meth(inst, *c_args, **c_kwargs))
File "/trytond/model/modelview.py", line 677, in on_change
method()
File "/trytond/model/modelview.py", line 84, in wrapper
result = func(self, *args, **kwargs)
File "/trytond/model/fields/field.py", line 114, in wrapper
return func(self, *args, **kwargs)
File "/trytond/modules/tri_jda/jda.py", line 189, in on_change_lodnum
rec.save(recs)
File "/trytond/model/descriptors.py", line 33, in newfunc
return self.func(owner, *args, **kwargs)
File "/trytond/model/modelstorage.py", line 1532, in save
news = cls.create([save_values[r] for r in to_create])
File "/trytond/model/modelsql.py", line 580, in create
[insert_values], [
table.id]))
File "/trytond/backend/postgresql/database.py", line 61, in execute
cursor.execute(self, sql, args)
psycopg2.InternalError: cannot execute INSERT in a read-only transaction
---------------------------------
Above is my stacktrace.
I am going to integrate with some WMS system for receiving. When user input the PO number which is "Lodnum" then tryton "on_change" and will display the WMS data to the list (MS SQL Server).
Background, after "on_change", I will read data from MSSQL. And insert to Tryton postgres.
But when inserted, above error occurred.