I'm developing a small utility script for trac which needs to know which is the max ticket id present in each environment.
At this time (with trac 0.11) I'm getting this extracting directly from the trac database with sqlite api, but since we have several environments with different database systems, the intended small utility script is getting bigger doing stupid things.
Is there anything in the trac.* namespace which allows me to find the max ticket id present in an open Environment?
Something which gives me an array with all the tickets or a generator to iterate over all of them will solve my problem.
I can't use the query package because it's an automated/commandline script.