When you do a factory reset, the board is in Safe Mode, which means it will blink and stay yellow. Even when the device is online, it will blink yellow. So you can see the status of a Safe Mode device online, and if the Particle cloud tells you it is online, it probably is.
The code can certainly affect the connectivity of a board. With the Photon, there is a way to run code in different threads, but that isn't possible really with bluz as the hardware has less resources. So all code is run single threaded. If your user code blocks the system firmware from running (infinite loop, etc) then the board can't connect.
As for pulseIn, there are just some functions we don't support yet, due to issues with the underlying architecture of the nrf51822 or other reasons. As I mentioned, the pulseIn can be affected by the radio, as it runs interrupts at the highest level which can affect the timing of the pulseIn function. There wasn't a great way to resolve that issue with bluz, so we left it unimplemented. While I agree that the code shouldn't compile and should present a user-friendly error, there is usually a good reason for those choices.
I am sorry for your frustrations, but bluz isn't a Photon, and it wasn't meant to be. There are always going to be things that bluz can't do compared to a Photon, and there are things a Photon can't do compared to bluz (try running a Photon on a coin cell battery, it won't even start). Different boards have different strengths and weaknesses, they should be chosen for any project base on those.
Bluz will continue to improve as we update to newer versions of the Particle firmware and add more features ourselves. But the underlying hardware is restrained by a much smaller processor and much less RAM than the Photon, so there are limits of what we can do (until bluz2!). So please let us know if you run into issues, we can help and we try to make the transition as simple as possible from a Photon to bluz, but it is generally a good mindset to not think of them as completely interchangeable.