MCPcopy Index your code
hub / github.com/masterking32/MasterHttpRelayVPN / _cache_allowed

Method _cache_allowed

src/proxy/proxy_server.py:336–343  ·  view source on GitHub ↗
(self, method: str, url: str,
                       headers: dict | None, body: bytes)

Source from the content-addressed store, hash-verified

334 return host_matches_rules(host, self._bypass_hosts)
335
336 def _cache_allowed(self, method: str, url: str,
337 headers: dict | None, body: bytes) -> bool:
338 if method.upper() != "GET" or body:
339 return False
340 for name in UNCACHEABLE_HEADER_NAMES:
341 if header_value(headers, name):
342 return False
343 return self.fronter._is_static_asset_url(url)
344
345 async def start(self):
346 if self._warmup_before_listen:

Callers 2

_relay_http_streamMethod · 0.95
_do_httpMethod · 0.95

Calls 2

header_valueFunction · 0.85
_is_static_asset_urlMethod · 0.80

Tested by

no test coverage detected