How to prove the union of languages recognized by a set of turing-recognizable Turing machines is also turing-recognizable?
Your enumerator is incorrect. Because there are infinitely many Turing machine descriptions in $G$, the loop corresponding to Line 3 will not halt, so i will never be increased. Also, Line 3.2 may not halt too.

The correct enumerator is:

E' = 
for i = 1 to infinity:
    Run E, the enumerator of G, to get the ith description of Turing machine &lt;Mi&gt;
    Build an enumerator Ei for Mi 
    for j = 1 to i - 1:
        Run Ej to get the ith string, print it
    Run Ei to get the first i strings, print them


Suppose $E_i$ prints $s_{i1},s_{i2},\ldots$ in order. Then after $i$ iterations, $E'$ would have printed $s_{11},\ldots,s_{1i},s_{21},\ldots,s_{2i},\ldots,s_{i1},\ldots,s_{ii}$ (note this is not the order they are printed), and would print $s_{1(i+1)},s_{2(i+1)},\ldots,s_{i(i+1)},s_{(i+1)1},\ldots,s_{(i+1)(i+1)}$ in order in the $(i+1)$th iteration. Of course, before printing a string, you can check if it has been printed to avoid duplicates.