Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
wiseplat
GitHub Repository: wiseplat/python-code
Path: blob/master/ invest-robot-contest_TinkoffBotTwitch-main/venv/lib/python3.8/site-packages/yarl/_quoting.py
7771 views
1
import os
2
import sys
3
4
__all__ = ("_Quoter", "_Unquoter")
5
6
7
NO_EXTENSIONS = bool(os.environ.get("YARL_NO_EXTENSIONS")) # type: bool
8
if sys.implementation.name != "cpython":
9
NO_EXTENSIONS = True
10
11
12
if not NO_EXTENSIONS: # pragma: no branch
13
try:
14
from ._quoting_c import _Quoter, _Unquoter # type: ignore[misc]
15
except ImportError: # pragma: no cover
16
from ._quoting_py import _Quoter, _Unquoter # type: ignore[misc]
17
else:
18
from ._quoting_py import _Quoter, _Unquoter # type: ignore[misc]
19
20