diff options
| author | jeffrey k eliasen <jeff@jke.net> | 2018-05-15 14:13:04 -0400 |
|---|---|---|
| committer | jeffrey k eliasen <jeff@jke.net> | 2018-05-15 14:13:04 -0400 |
| commit | 8806d73c0b03b3304dc0edd83582c085d0b71299 (patch) | |
| tree | 17d199a8de614eea03451186b4a63117183e5632 /pkg_resources | |
| parent | 3159321c932202f352f6878d833b8d52463d8858 (diff) | |
| download | python-setuptools-git-8806d73c0b03b3304dc0edd83582c085d0b71299.tar.gz | |
implementation
Diffstat (limited to 'pkg_resources')
| -rw-r--r-- | pkg_resources/__init__.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/pkg_resources/__init__.py b/pkg_resources/__init__.py index d5b0fe98..09c3546a 100644 --- a/pkg_resources/__init__.py +++ b/pkg_resources/__init__.py @@ -2667,6 +2667,15 @@ class Distribution(object): raise AttributeError(attr) return getattr(self._provider, attr) + def __dir__(self): + return list( + set(super(Distribution, self).__dir__()) + | set( + attr for attr in self._provider.__dir__() + if not attr.startswith('_') + ) + ) + @classmethod def from_filename(cls, filename, metadata=None, **kw): return cls.from_location( |
