Moved argparsing into function, updated error handling for validate module.
Moved argparsing into function, updated error handling for validate module.

UCL-RITS/rcps-rcops-scripts,UCL-RITS/rcps-rcops-scripts,UCL-RITS/rcps-rcops-scripts