Skip to content

Commit

Permalink
Add error type to raise statement
Browse files Browse the repository at this point in the history
Summary: Pull Request resolved: #15039

Differential Revision: D13419566

Pulled By: zou3519

fbshipit-source-id: f67a3aebce937e3e640e91e81eb3e184cfdf269c
  • Loading branch information
daniel-s-ingram authored and facebook-github-bot committed Dec 12, 2018
1 parent 73ee7fd commit 5c2c40a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion caffe2/python/model_helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ def create_param(self, param_name, shape, initializer, tags=None):
param_name = parameter_sharing_context.get_parameter_name(
param_name)
else:
raise "Unsupported type for param_name"
raise TypeError("Unsupported type for param_name")

if param_name in self._parameters_info:
assert self._parameters_info[param_name].shape == shape
Expand Down

0 comments on commit 5c2c40a

Please sign in to comment.