Skip to content

AttributeError: module 'elasticsearch.helpers' has no attribute 'async_bulk' in version 7.9.0 #1350

Closed
@jabonte

Description

@jabonte

Ran into the following problem after upgrading to version 7.9.0
AttributeError: module 'elasticsearch.helpers' has no attribute 'async_bulk'

Installed older version to verify:
pip3 install --user elasticsearch[async]==7.8.1
Collecting elasticsearch[async]==7.8.1
Using cached https://files.pythonhosted.org/packages/76/7f/8dd4c7e1895d99e16c9b78fea1e0e0a64382f53bc9fc655a01465de70505/elasticsearch-7.8.1-py2.py3-none-any.whl
Successfully installed elasticsearch-7.8.1

Ran one-liner to verify that async_bulk can be loaded
python3 -c "from elasticsearch.helpers import async_bulk"

Checked local file-system
ls ~/.local/lib/python3.6/site-packages/elasticsearch/_async/
client compat.py helpers.py http_aiohttp.py init.py pycache transport.py

Installed version 7.9.0
pip3 install --user elasticsearch[async]==7.9.0
Collecting elasticsearch[async]==7.9.0
Using cached https://files.pythonhosted.org/packages/c6/63/ff0c908cae1e8e000308cba1d647585dff3dffad5304ca12fe834297fe8f/elasticsearch-7.9.0-py2.py3-none-any.whl
Successfully installed elasticsearch-7.9.0

Ran one-liner to verify that async_bulk can be loaded
python3 -c "from elasticsearch.helpers import async_bulk"
Traceback (most recent call last):
File "", line 1, in
ImportError: cannot import name 'async_bulk'

Checked local file-system
ls ~/.local/lib/python3.6/site-packages/elasticsearch/_async/
client compat.py http_aiohttp.py init.py pycache transport.py

Looks like file _async/helpers.py is missing
But it is still present in GIT
https://github.com/elastic/elasticsearch-py/blob/master/elasticsearch/_async/helpers.py

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions