OXIESEC PANEL
- Current Dir:
/
/
snap
/
certbot
/
4730
/
usr
/
lib
/
python3
/
dist-packages
/
pip
/
_vendor
/
cachecontrol
Server IP: 139.59.38.164
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
06/10/2025 09:51:14 PM
rwxr-xr-x
📄
__init__.py
676 bytes
10/18/2024 05:04:47 PM
rw-r--r--
📄
_cmd.py
1.7 KB
10/18/2024 05:04:47 PM
rw-r--r--
📄
adapter.py
6.24 KB
10/18/2024 05:04:47 PM
rw-r--r--
📄
cache.py
1.91 KB
10/18/2024 05:04:47 PM
rw-r--r--
📁
caches
-
06/10/2025 09:51:14 PM
rwxr-xr-x
📄
controller.py
17.95 KB
10/18/2024 05:04:47 PM
rw-r--r--
📄
filewrapper.py
4.19 KB
10/18/2024 05:04:47 PM
rw-r--r--
📄
heuristics.py
4.71 KB
10/18/2024 05:04:47 PM
rw-r--r--
📄
serialize.py
7 KB
10/18/2024 05:04:47 PM
rw-r--r--
📄
wrapper.py
1.38 KB
10/18/2024 05:04:47 PM
rw-r--r--
Editing: wrapper.py
Close
# SPDX-FileCopyrightText: 2015 Eric Larson # # SPDX-License-Identifier: Apache-2.0 from __future__ import annotations from typing import TYPE_CHECKING, Collection from pip._vendor.cachecontrol.adapter import CacheControlAdapter from pip._vendor.cachecontrol.cache import DictCache if TYPE_CHECKING: from pip._vendor import requests from pip._vendor.cachecontrol.cache import BaseCache from pip._vendor.cachecontrol.controller import CacheController from pip._vendor.cachecontrol.heuristics import BaseHeuristic from pip._vendor.cachecontrol.serialize import Serializer def CacheControl( sess: requests.Session, cache: BaseCache | None = None, cache_etags: bool = True, serializer: Serializer | None = None, heuristic: BaseHeuristic | None = None, controller_class: type[CacheController] | None = None, adapter_class: type[CacheControlAdapter] | None = None, cacheable_methods: Collection[str] | None = None, ) -> requests.Session: cache = DictCache() if cache is None else cache adapter_class = adapter_class or CacheControlAdapter adapter = adapter_class( cache, cache_etags=cache_etags, serializer=serializer, heuristic=heuristic, controller_class=controller_class, cacheable_methods=cacheable_methods, ) sess.mount("http://", adapter) sess.mount("https://", adapter) return sess