I believe 10.0 is the max for stamina. So it looks like the algorithm calculates training effects first and then skill drops.
As your player`s stamina was already at 10, it could not go any higher, so it decreased after the skill drop occurrence.
Still it definitely should not work like that and to me the easiest solution is to refactor the code so that drops are calculated before pops.