Skip to content

Commit d141caf

Browse files
committed
- better exception message interpolation, as per #44 (comment)
1 parent 77e6116 commit d141caf

File tree

1 file changed

+4
-3
lines changed
  • aws_lambda_builders/workflows/nodejs_npm

1 file changed

+4
-3
lines changed

aws_lambda_builders/workflows/nodejs_npm/npm.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,15 @@
44

55
import logging
66

7-
from aws_lambda_builders.exceptions import LambdaBuilderError
8-
97
LOG = logging.getLogger(__name__)
108

119

12-
class NpmExecutionError(LambdaBuilderError):
10+
class NpmExecutionError(Exception):
1311
MESSAGE = "NPM Failed: {message}"
1412

13+
def __init__(self, **kwargs):
14+
Exception.__init__(self, self.MESSAGE.format(**kwargs))
15+
1516

1617
class SubprocessNpm(object):
1718

0 commit comments

Comments
 (0)