diff options
| author | Vadim Markovtsev <v.markovtsev@samsung.com> | 2015-11-01 12:35:38 +0300 |
|---|---|---|
| committer | Vadim Markovtsev <v.markovtsev@samsung.com> | 2015-11-01 12:35:38 +0300 |
| commit | 57ebfa41e0f96b97e599ecd931b7ae8a143e096e (patch) | |
| tree | d4d57e1b16060819a60155afdf2a6400beb2bbc4 /pkg_resources | |
| parent | ae6c73f07680da77345f5ccfac4facde30ad4d7e (diff) | |
| download | python-setuptools-git-57ebfa41e0f96b97e599ecd931b7ae8a143e096e.tar.gz | |
Fix "dictionary changed size during iteration"
env is being modified at the same time as being iterated which leads to RuntimeError: dictionary changed size during iteration.
Diffstat (limited to 'pkg_resources')
| -rw-r--r-- | pkg_resources/__init__.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pkg_resources/__init__.py b/pkg_resources/__init__.py index ae363755..df662dfe 100644 --- a/pkg_resources/__init__.py +++ b/pkg_resources/__init__.py @@ -1536,7 +1536,7 @@ class MarkerEvaluation(object): # markerlib implements Metadata 1.2 (PEP 345) environment markers. # Translate the variables to Metadata 2.0 (PEP 426). env = _markerlib.default_environment() - for key in env.keys(): + for key in tuple(env.keys()): new_key = key.replace('.', '_') env[new_key] = env.pop(key) try: |
