Derpseh / Spyglass

Nationstates Sheet-generator for easily finding approximate update times
GNU General Public License v3.0
11 stars 10 forks source link

Switch ElementTree with lxml? #20

Closed khronion closed 2 years ago

khronion commented 2 years ago

lxml is a bit faster than ElementTree, but not by much, and it doesn't ship with Python. We could switch pretty easily by changing the ElementTree import to the following:

from lxml import etree as ElementTree

In my testing, switching led to a 10% speed up, but in practice that was only 2 seconds.

khronion commented 2 years ago

Even that 10% speedup isn't consistent, so maybe we have to condense all the loops together...