diff --git a/CHANGELOG.md b/CHANGELOG.md index 6091ab0e..517a4b49 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,11 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/) and this project adheres to [Semantic Versioning](http://semver.org/). +## [2.0.7] - 2017-08-06 + +### Fixes +- Fixed entry point breaking pip + ## [2.0.6] - 2017-08-05 ### Fixes diff --git a/fs/_version.py b/fs/_version.py index ff6ef86d..962c851b 100644 --- a/fs/_version.py +++ b/fs/_version.py @@ -1 +1 @@ -__version__ = "2.0.6" +__version__ = "2.0.7" diff --git a/fs/opener/registry.py b/fs/opener/registry.py index e7e50371..32151b61 100644 --- a/fs/opener/registry.py +++ b/fs/opener/registry.py @@ -95,15 +95,22 @@ def __init__(self, default_opener='osfs'): """ self.default_opener = default_opener - self.protocols = [ - entry_point.name - for entry_point in - pkg_resources.iter_entry_points('fs.opener') - ] + self._protocols = None + def __repr__(self): return "".format(self.protocols) + @property + def protocols(self): + if self._protocols is None: + self._protocols = [ + entry_point.name + for entry_point in + pkg_resources.iter_entry_points('fs.opener') + ] + return self._protocols + def get_opener(self, protocol): """ Get the opener class associated to a given protocol.