Added code for checking if launch_spec exists on the node. Some edge cases were failing.