MCPcopy Index your code
hub / github.com/mongodb/mongo-python-driver / _resolve

Function _resolve

pymongo/asynchronous/srv_resolver.py:49–57  ·  view source on GitHub ↗
(*args: Any, **kwargs: Any)

Source from the content-addressed store, hash-verified

47
48# PYTHON-2667 Lazily call dns.resolver methods for compatibility with eventlet.
49async def _resolve(*args: Any, **kwargs: Any) -> resolver.Answer:
50 if _IS_SYNC:
51 from dns import resolver
52
53 return resolver.resolve(*args, **kwargs)
54 else:
55 from dns import asyncresolver
56
57 return await asyncresolver.resolve(*args, **kwargs) # type:ignore[return-value]
58
59
60_INVALID_HOST_MSG = (

Callers 2

get_optionsMethod · 0.70
_resolve_uriMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected