Kaynağa Gözat

Update links validation user-agent (#1428)

pull/1287/head
Pierre-Yves Aillet 3 yıl önce
committed by GitHub
ebeveyn
işleme
dc38eb60b0
Veri tabanında bu imza için bilinen anahtar bulunamadı GPG Anahtar Kimliği: 4AEE18F83AFDEB23
1 değiştirilmiş dosya ile 1 ekleme ve 1 silme
  1. +1
    -1
      build/validate_links.py

+ 1
- 1
build/validate_links.py Dosyayı Görüntüle

@@ -24,7 +24,7 @@ def validate_links(links):
for link in links:
h = httplib2.Http(disable_ssl_certificate_validation=True, timeout=25)
try:
resp = h.request(link, headers={'user-agent': 'python-httplib2/0.9.2'})
resp = h.request(link, headers={'user-agent': 'python-httplib2/0.18.0'})
code = int(resp[0]['status'])
# check if status code is a client or server error
if code >= 404:


Yükleniyor…
İptal
Kaydet