Why is the EV3 Ultrasonic Sensor (45504) out of stock? The EV3 Ultrasonic Sensor (45504) has been out of stock for a long time.  Is the sensor discontinued due to an accuracy problem?

Is there an alternate version of "Gyro Boy" that works without the Ultrasonic Sensor and uses Infrared instead? 

https://le-www-live-s.legocdn.com/sc/media/lessons/mindstorms-ev3/building-instructions/ev3-model-core-set-gyro-boy-f8a14d8e3d0e63fa23b87f798bf197f4.pdf
Balanc3r is a good alternative for gyro-boy:
http://robotsquare.com/2014/06/23/tutorial-building-balanc3r/

However, why do you conclude that the 45504 sensor is out of stock?
In my region (Belgium) it can be ordered from the lego website and is listed as "Available", also it is contained in the core educational set (45544) which is certainly still available from various sources...