Виджет с усреднёнными точками на карте
This commit is contained in:
@@ -40,7 +40,7 @@ def get_footprint_data(position: str = 62) -> dict:
|
||||
|
||||
def get_all_page_data(url:str = 'https://www.satbeams.com/footprints') -> dict:
|
||||
"""Возвращает словарь с данными по всем спутникам на странице"""
|
||||
response = requests.get(url, verify="/etc/ssl/certs/ca-certificates.crt")
|
||||
response = requests.get(url)
|
||||
response.raise_for_status()
|
||||
match = re.search(r'var data = ({.*?});', response.text, re.DOTALL)
|
||||
if match:
|
||||
|
||||
@@ -86,7 +86,7 @@ class TileProxyView(View):
|
||||
url = f"{self.TILE_BASE_URL}/{footprint_name}/{z}/{x}/{y}.png"
|
||||
|
||||
try:
|
||||
resp = requests.get(url, timeout=self.REQUEST_TIMEOUT, verify=r'/home/vesemir/DataStorage/cert.pem')
|
||||
resp = requests.get(url, timeout=self.REQUEST_TIMEOUT)
|
||||
if resp.status_code == 200:
|
||||
response = HttpResponse(resp.content, content_type="image/png")
|
||||
response["Access-Control-Allow-Origin"] = "*"
|
||||
|
||||
Reference in New Issue
Block a user