When a program streams any audio (even silence), the system don't go into sleep mode automatically. Sometimes it is not desired (e.g. if you use Sound Keeper). You can try to use the powercfg to allow Windows go into sleep mode even when audio is streamed.