adding handling for the "format" option for output
adding custom "format not found" exception