Error
For example, calling the above code to run CL command "DLTLIB LIB(NOTEXISTS)", then an error is reported as below. The error doesn't appear on English system.
Traceback (most recent call last):
File "/tmp/ansible_ibmi_object_save_payload_bwwr4eug/ansible_ibmi_object_save_payload.zip/ansible/module_utils/ibmi/ibmi_util.py", line 173, in itoolkit_run_command
File "/QOpensys/pkgs/lib/python3.6/site-packages/itoolkit/itoolkit.py", line 1155, in call
xml_out = itrans.call(self)
File "/QOpensys/pkgs/lib/python3.6/site-packages/itoolkit/transport/database.py", line 66, in call
return "".join(row[0] for row in cursor).rstrip('\0')
File "/QOpensys/pkgs/lib/python3.6/site-packages/itoolkit/transport/database.py", line 66, in
return "".join(row[0] for row in cursor).rstrip('\0')
File "/QOpensys/pkgs/lib/python3.6/site-packages/ibm_db_dbi.py", line 1128, in next
row = self.fetchone()
File "/QOpensys/pkgs/lib/python3.6/site-packages/ibm_db_dbi.py", line 1492, in fetchone
row_list = self._fetch_helper(1)
File "/QOpensys/pkgs/lib/python3.6/site-packages/ibm_db_dbi.py", line 1476, in _fetch_helper
raise self.messages[-1]
ibm_db_dbi.Error: ibm_db_dbi::error: SystemError(' returned a result with an error set',)
Have no idea why the can't be displayed on the git issue. So put a snapshot here.
Describe the bug
Code
conn = dbi.connect() itool = iToolKit() itransport = DatabaseTransport(conn) itool.add(iCmd('command1', command, {'error': 'on'})) itool.call(itransport) command_output = itool.dict_out('command1')
Error For example, calling the above code to run CL command "DLTLIB LIB(NOTEXISTS)", then an error is reported as below. The error doesn't appear on English system.
Traceback (most recent call last): File "/tmp/ansible_ibmi_object_save_payload_bwwr4eug/ansible_ibmi_object_save_payload.zip/ansible/module_utils/ibmi/ibmi_util.py", line 173, in itoolkit_run_command File "/QOpensys/pkgs/lib/python3.6/site-packages/itoolkit/itoolkit.py", line 1155, in call xml_out = itrans.call(self) File "/QOpensys/pkgs/lib/python3.6/site-packages/itoolkit/transport/database.py", line 66, in call return "".join(row[0] for row in cursor).rstrip('\0') File "/QOpensys/pkgs/lib/python3.6/site-packages/itoolkit/transport/database.py", line 66, in
return "".join(row[0] for row in cursor).rstrip('\0')
File "/QOpensys/pkgs/lib/python3.6/site-packages/ibm_db_dbi.py", line 1128, in next
row = self.fetchone()
File "/QOpensys/pkgs/lib/python3.6/site-packages/ibm_db_dbi.py", line 1492, in fetchone
row_list = self._fetch_helper(1)
File "/QOpensys/pkgs/lib/python3.6/site-packages/ibm_db_dbi.py", line 1476, in _fetch_helper
raise self.messages[-1]
ibm_db_dbi.Error: ibm_db_dbi::error: SystemError(' returned a result with an error set',)
Have no idea why the can't be displayed on the git issue. So put a snapshot here.