Mine started to do a similar thing. The preference are set to never sleep, but the machine goes to sleep in the middle of the night regardless, and there are active encode processes. The only thing in the console log is a number of AFP disconnects prior to going to sleep at just before 2AM. Seems to continue to work fine once woken up.
Seems that most sleep issues here are failure to sleep or not waking up.... don't recall seeing one where the machine sleeps regardless. Perhaps it just tired, I have been working it kinda hard 🙂
I use OS 10.6.8 on this early 2008 MacPro.