Skip to content

Files

Latest commit

 

History

History
24 lines (16 loc) · 545 Bytes

Style-ImplicitRuntimeError.md

File metadata and controls

24 lines (16 loc) · 545 Bytes

Pattern: Implicit runtime error

Issue: -

Description

This rule checks for raise or fail statements which do not specify an explicit exception class. (This raises a RuntimeError. Some projects might prefer to use exception classes which more precisely identify the nature of the error.)

Examples

# bad
raise 'Error message here'

# good
raise ArgumentError, 'Error message here'

Further Reading