[SOLVED] Apparently I didn't passed correctly one of the variables from TCS to TES. Strangely it was a quite irrelevant one, but now is fixed.