techtonik / python-patch

Library to parse and apply unified diffs
https://pypi.python.org/pypi/patch
112 stars 65 forks source link

fromfile() should either return None or raise an exception, not return False #57

Open stefanoborini opened 5 years ago

stefanoborini commented 5 years ago

It makes little sense to change the return type of fromfile. Either it's an object (or None if it fails) or it raises an Exception if it fails. Returning an object or a boolean if fails is inconsistent.