Add safety checks
Merge pull request #84 from fluxroot/JCPI-41-add-safety-checks

Add safety checks

JCPI-41 #wait