Skip to content

Setting "sniff_before_requests=True" leads to repeatedly retrieving fail sniff tasks during requests #256

@jackatls

Description

@jackatls

sorry my english is poor

in elastic_transport/_async_transport.py

when sniff_before_requests=True,sniff function call is not wrapped in a try-catch block, which causes exceptions from task.result to propagate outward.
Image

Image

If last sniff task return a timeout exception,this sniff(False) function will repeatedly retrieving failed sniff task Exception and never recover

and I observed other place using the func will wrap it with try catch

Image

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