Closed ams1234 closed 3 years ago
Hello ams1234,
You found an interesting issue. The traceback says, the TL server response XML data section is not valid - some closing XML tag is missing.
So it looks for a server problem - do you see inside the TL server or Web server logs with a matching time stamp?
If you want to see/analyse hugh xml output, you can enable the TL api client debugging mode - see How to check original exchanged XML data.
An alternative if you just want to make it running, what about calling getTestCasesForTestplan with some optional args to reduce the output? List of arguments see mytestlink.whatArgs('getTestCasesForTestplan')
Hope this helps a little.
Regards Luiko
Thank you for the reply, that was really quick will check and get back with the status.
Hello lczub,
Have checked the api call with giving optional arguments .... one of the options which is relevant is platform id , do testlink api has any api for getting all the platforms from the testlink server. Searched on the internet , could not get any example can you please provide the link for the documentation for the same or just an example
Hello ams1234,
what about the samples included in this project?
You find sample calls with comments in TestLinkExampleGenericApi.py
Regards Luiko
no further response
While using testlink api for getting the test cases based on testplan, for testplans with fewer testcases it works fine but for the testplan with many testcases the same api is not working .
I am executing the following lines to get the testcases of the testplan
from testlink import TestlinkAPIClient, TestLinkHelper, TestGenReporter, TestlinkAPIGeneric tl_helper = TestLinkHelper() myTestLink = tl_helper.connect(TestlinkAPIGeneric) mytestlink.getTestCasesForTestplan(plan_id)
and the error i am getting is as follows Traceback (most recent call last): File "", line 1, in
File "/usr/local/lib/python3.6/site-packages/testlink/testlinkdecorators.py", line 140, in wrapperReplaceTLResponseError
response = methodAPI(self, *argsPositional, argsOptional)
File "/usr/local/lib/python3.6/site-packages/testlink/testlinkdecorators.py", line 112, in wrapperAddDevKey
return methodAPI(self, *argsPositional, *argsOptional)
File "/usr/local/lib/python3.6/site-packages/testlink/testlinkdecorators.py", line 100, in wrapperWithArgs
argsPositional, argsOptional)
File "/usr/local/lib/python3.6/site-packages/testlink/testlinkapigeneric.py", line 1582, in callServerWithPosArgs
response = self._callServer(methodNameAPI, argsOptional)
File "/usr/local/lib/python3.6/site-packages/testlink/testlinkapigeneric.py", line 2057, in _callServer
response = getattr(self.server.tl, methodNameAPI)(argsAPI)
File "/usr/lib64/python3.6/xmlrpc/client.py", line 1112, in call
return self.send(self.name, args)
File "/usr/lib64/python3.6/xmlrpc/client.py", line 1452, in request
verbose=self.verbose
File "/usr/lib64/python3.6/xmlrpc/client.py", line 1154, in request
return self.single_request(host, handler, request_body, verbose)
File "/usr/lib64/python3.6/xmlrpc/client.py", line 1170, in single_request
return self.parse_response(resp)
File "/usr/lib64/python3.6/xmlrpc/client.py", line 1340, in parse_response
p.close()
File "/usr/lib64/python3.6/xmlrpc/client.py", line 448, in close
parser.Parse(b"", True) # end of data
xml.parsers.expat.ExpatError: unclosed token: line 218149, column 0
what night be the reason ?