RedHatQE / pylero

Python wrapper for the Polarion WSDL API
https://redhatqe.github.io/pylero/
MIT License
38 stars 25 forks source link

Update status of Testrun using pylero-cmd got error #133

Closed jayesh-garg closed 1 year ago

jayesh-garg commented 1 year ago

Getting traceback: `Update Testrun_ABC_example: Total records: 118 Updated Date Time Result CaseID


2023-04-05 05:32:44 passed ITEM-7810 Traceback (most recent call last): File "/usr/local/lib/python3.6/site-packages/suds/transport/http.py", line 89, in send fp = self.u2open(u2request, timeout=request.timeout) File "/usr/local/lib/python3.6/site-packages/suds/transport/http.py", line 140, in u2open return url.open(u2request, timeout=tm) File "/usr/lib64/python3.6/urllib/request.py", line 532, in open response = meth(req, response) File "/usr/lib64/python3.6/urllib/request.py", line 642, in http_response 'http', request, response, code, msg, hdrs) File "/usr/lib64/python3.6/urllib/request.py", line 570, in error return self._call_chain(args) File "/usr/lib64/python3.6/urllib/request.py", line 504, in _call_chain result = func(args) File "/usr/lib64/python3.6/urllib/request.py", line 650, in http_error_default raise HTTPError(req.full_url, code, msg, hdrs, fp) urllib.error.HTTPError: HTTP Error 500: 500

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/usr/local/lib/python3.6/site-packages/suds/client.py", line 771, in send reply = self.options.transport.send(request) File "/usr/local/lib/python3.6/site-packages/suds/transport/https.py", line 66, in send return HttpTransport.send(self, request) File "/usr/local/lib/python3.6/site-packages/suds/transport/http.py", line 106, in send raise TransportError(e.msg, e.code, e.fp) suds.transport.TransportError: 500

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/usr/local/bin/pylero-cmd", line 291, in cli() File "/usr/local/lib/python3.6/site-packages/click/core.py", line 1128, in call return self.main(args, kwargs) File "/usr/local/lib/python3.6/site-packages/click/core.py", line 1053, in main rv = self.invoke(ctx) File "/usr/local/lib/python3.6/site-packages/click/core.py", line 1659, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File "/usr/local/lib/python3.6/site-packages/click/core.py", line 1395, in invoke return ctx.invoke(self.callback, ctx.params) File "/usr/local/lib/python3.6/site-packages/click/core.py", line 754, in invoke return __callback(args, *kwargs) File "/usr/local/bin/pylero-cmd", line 279, in update run, result, assignee, comment File "/usr/local/lib/python3.6/site-packages/pylero/cli/cmd.py", line 228, in update_all_case_results_for_runs self.update_all_case_results_for_run(run, result, user, comment) File "/usr/local/lib/python3.6/site-packages/pylero/cli/cmd.py", line 222, in update_all_case_results_for_run tr.update_test_record_by_object(rec.test_case_id, rec) File "/usr/local/lib/python3.6/site-packages/pylero/base_polarion.py", line 228, in inner res = func(args, **kwargs) File "/usr/local/lib/python3.6/site-packages/pylero/test_run.py", line 1318, in update_test_record_by_object self.uri, index, suds_object File "/usr/local/lib/python3.6/site-packages/suds/client.py", line 586, in call return client.invoke(args, kwargs) File "/usr/local/lib/python3.6/site-packages/suds/client.py", line 728, in invoke result = self.send(soapenv, timeout=timeout) File "/usr/local/lib/python3.6/site-packages/suds/client.py", line 776, in send return self.process_reply(content, e.httpcode, tostr(e)) File "/usr/local/lib/python3.6/site-packages/suds/client.py", line 840, in process_reply raise WebFault(fault, replyroot) suds.WebFault: Server raised fault: 'java.lang.IllegalArgumentException: URI scheme null is not subterra' [root@kvm-08-guest17 ~]#`

waynesun09 commented 1 year ago

@jayesh-garg Thanks for report the issue, though please don't include specific internal details like the whole run name include product info in public repo, so I have to edit it.

For the issue itself, when you report please provide:

  1. pylero version
  2. reproduce steps
leelavg commented 1 year ago

File "/usr/local/lib/python3.6/site-packages/pylero/test_run.py", line 1318, in update_test_record_by_object self.uri, index, suds_object

  • excep seems to have originated from here, however not able to deduct what version/commit you are using
  • btw, afaik we don't pkg pylero-cmd
waynesun09 commented 1 year ago

Test with our instance base on analysis the log and comment:

$ pylero-cmd update --run="example test run xxx" --result "failed"
Update example test run xxx:
Total records: 1
Updated Date Time    Result  CaseID
-------------------  ------  -----------
2023-05-16 11:42:11  failed  Testcase-449
Done!

it works with current 0.0.8 release and also with main branch install.

For the pylero-cmd it's not fully supported, so please use the pylero CLI or use library directly.

As could not reproduce and no response from user, close this for now, feel free to reopen if issue still exist.