aiobotocore: get_credentials() fails on AioSession
Using aiobotocore 0.6.0, python 3.6.3
Executing:
aiobotocore.get_session().get_credentials().secret_key
Fails with the following error:
Traceback (most recent call last):
File "<input>", line 1, in <module>
File "/venv/lib/python3.6/site-packages/botocore/credentials.py", line 336, in secret_key
self._refresh()
File "/venv/lib/python3.6/site-packages/botocore/credentials.py", line 415, in _refresh
self._protected_refresh(is_mandatory=is_mandatory_refresh)
File "/venv/lib/python3.6/site-packages/botocore/credentials.py", line 431, in _protected_refresh
metadata = self._refresh_using()
File "/venv/lib/python3.6/site-packages/botocore/credentials.py", line 555, in fetch_credentials
return self._get_cached_credentials()
File "/venv/lib/python3.6/site-packages/botocore/credentials.py", line 566, in _get_cached_credentials
self._write_to_cache(response)
File "/venv/lib/python3.6/site-packages/botocore/credentials.py", line 591, in _write_to_cache
self._cache[self._cache_key] = deepcopy(response)
File "/usr/lib/python3.6/copy.py", line 169, in deepcopy
rv = reductor(4)
TypeError: can't pickle generator objects
When hitting the AssumeRoleProvider. It appears that the provider tries to write the client to cache but fails to serialize the Aio client.
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Reactions: 1
- Comments: 15 (1 by maintainers)
temp monkeypatch fix: