t[parts[i]+1 : parts[i+1]] is not type stable, unless the compiler can know ahead of time that this is of constant length as a function of i, like in your type stable example.
Instead of slicing to make tuples of dynamic lengths, use a loop or prod with a function argument to index into t.