After much headache, found out that lib/wavelength.js was giving an error probably because of an encoding issue with the file...........