Can I get the number of tickets using the Trac XML-RPC Plugin, without requiring all tickets from the server?
The trac API describes parameter "format=count", but it does not work for me ...
I'm trying to run the following code:
import xmlrpclib
server = xmlrpclib.ServerProxy("https://user:password@trac-server/login/xmlrpc")
multicall = xmlrpclib.MultiCall(server)
for t in server.ticket.query('status=new&format=count&max=3'):
print t
... but get only ticket numbers, not the number of it.
I can count so:
import xmlrpclib
server = xmlrpclib.ServerProxy("https://user:password@trac-server/login/xmlrpc")
multicall = xmlrpclib.MultiCall(server)
print( server.ticket.query('max=0') )
... but I think it's not a very optimal way, because this method loads all data from the server.
Is there a way to get the number of tickets without requiring a complete list and counting it?