What exactly does Studio when importing TMX to TM?

I'm having some weird difficulties with my STraSAK TMX import - the import crashes (in my case actually the entire Powershell process!) at unpredictable point of the import...
The problems start happening with Studio 2017 SR1 CU16 - in my testing machine I tried all CUs starting with CU10 and the import worked well until CU15. When I upgraded to CU16, the import started crashing.

Doing import manually inside Studio works well... so I tried to "trace" what Studio does during import (what I might not be doing in my code).

And I'd like to have some clarification from SDL here... because Studio seems to perform the import actually three times or what... :-O
The video below shows the import process:
0:02 - 0:08 happens the first import
0:08 - 0:11 happens the second import
0:11 - 0:15 happens the third import
0:15 Studio recomputes fuzzy indexes
What's going on there?!?!

Moreover, the TMX has 2511 TUs, so how come that the "Read" counter goes up to 2611?!?! And why only during the 1st and 3rd import?
And why the second import does not show any "Imported" TUs, while the first shows 2511 and third shows 2507?!

What kind of woodoo is going on there?!
How is one supposed to implement properly working import purely using the public API and following the publicly available tutorials if Studio itself does such strange woodoo, presumably involving much more than just invoking the Import method?!?!

And what kind of changes im TMs (and/or their API) were introduced in Studio 2017 SR1 CU16 which may be causing the mysterious crashes?

EDIT:

What's more strange is that my import process to empty new SDLTM created using Studio 2015 works just fine (and it also shows that mysterious 2611 TUs out of 2511... "raw TUs" 2511, "read TUs" 2611... go figure...).
Import to empty new SDLTM created using Studio 2017 crashes.
That could mean that my process for creating new empty TM might be setting something wrong, or not setting something, etc.

Here are the two empty SDLTMs - does anyone see anything obviously wrong in the 2017 SDLTM?

2015.zip
 2017.zip