VID-1769 hopefully fixing race condition with videos module load. Also added debug logging