diff --git a/README.rst b/README.rst index 463db7c..5385199 100644 --- a/README.rst +++ b/README.rst @@ -32,6 +32,8 @@ Supported Files +------------------+------------+-----------+ | Pipfile.lock | yes | yes | +------------------+------------+-----------+ +| poetry.lock | yes | no | ++------------------+------------+-----------+ | setup.py | no (# 2_) | no (# 2_) | +------------------+------------+-----------+ | zc.buildout | no (# 3_) | no (# 3_) | diff --git a/dparse/errors.py b/dparse/errors.py index b7a6543..74fc99d 100644 --- a/dparse/errors.py +++ b/dparse/errors.py @@ -1,8 +1,19 @@ # -*- coding: utf-8 -*- from __future__ import unicode_literals, absolute_import + class UnknownDependencyFileError(Exception): """ """ - pass + def __init__(self, message="Unknown File type to parse"): + self.message = message + super().__init__(self.message) + + +class MalformedDependencyFileError(Exception): + + def __init__(self, message="The dependency file is malformed. {info}", + info=""): + self.message = message.format(info=info) + super().__init__(self.message)