Must be used only when 'ValueError' is raised. It occurs when inappropriate values of a correct datatype is used
ValueError : raised when a function receives an argument having the correct datatype but an inappropriate value
This answer can help out : What does ValueError mean?