diff --git a/CHANGELOG.md b/CHANGELOG.md index 7597621a..0449d14f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,6 +15,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/). - Include docs in source distributions as well the whole tests folder, ensuring `conftest.py` is present, fixes [#364](https://github.com/PyFilesystem/pyfilesystem2/issues/364). - Stop patching copy with Python 3.8+ because it already uses sendfile. +- Fixed crash when CPython's -OO flag is used ## [2.4.11] - 2019-09-07 diff --git a/CONTRIBUTORS.md b/CONTRIBUTORS.md index 432bf23a..de54b668 100644 --- a/CONTRIBUTORS.md +++ b/CONTRIBUTORS.md @@ -6,6 +6,7 @@ Many thanks to the following developers for contributing to this project: - [Diego Argueta](https://github.com/dargueta) - [Geoff Jukes](https://github.com/geoffjukes) - [Giampaolo](https://github.com/gpcimino) +- [Justin Charlong](https://github.com/jcharlong) - [Louis Sautier](https://github.com/sbraz) - [Martin Larralde](https://github.com/althonos) - [Will McGugan](https://github.com/willmcgugan) diff --git a/fs/base.py b/fs/base.py index a6218b93..5eb0b90b 100644 --- a/fs/base.py +++ b/fs/base.py @@ -84,7 +84,7 @@ def _method(*args, **kwargs): """.format( method.__name__ ) - if hasattr(_method, "__doc__"): + if getattr(_method, "__doc__", None) is not None: _method.__doc__ += deprecated_msg return _method