Fixes to get code running
Fixes to get code running

Some edits (code was crashing):

* tree.getpath(i) was failing due to i being set to a string instead of an etree object in the previous line. After fixing this issue I also renamed instances of i to "extent" to be more semantic
* the "with" statement closes the csv automatically; having the separate csvfile.close() line leads to a crash
* Python 3 compatibility (enclosing print statements in parens)
* Since etree is the only lxml function that is used, we can remove the full lxml import
eckardm/migration-tools,bentley-historical-library/migration-tools,djpillen/migration-tools