mirror of
https://github.com/wassname/ray.git
synced 2026-07-28 11:25:04 +08:00
Remove instances of 'raise Exception' (#7523)
This commit is contained in:
@@ -96,9 +96,9 @@ def extract_signature(func, ignore_first=False):
|
||||
|
||||
if ignore_first:
|
||||
if len(signature_parameters) == 0:
|
||||
raise Exception("Methods must take a 'self' argument, but the "
|
||||
"method '{}' does not have one.".format(
|
||||
func.__name__))
|
||||
raise ValueError("Methods must take a 'self' argument, but the "
|
||||
"method '{}' does not have one.".format(
|
||||
func.__name__))
|
||||
signature_parameters = signature_parameters[1:]
|
||||
|
||||
return _scrub_parameters(signature_parameters)
|
||||
|
||||
Reference in New Issue
Block a user