Kaynağa Gözat

Work around warcio not writing the correct WARC-Profile header for revisit records on WARC/1.1

https://github.com/webrecorder/warcio/issues/94
tags/v0.2.1
JustAnotherArchivist 4 yıl önce
ebeveyn
işleme
413435b7fb
1 değiştirilmiş dosya ile 2 ekleme ve 0 silme
  1. +2
    -0
      qwarc/warc.py

+ 2
- 0
qwarc/warc.py Dosyayı Görüntüle

@@ -154,6 +154,8 @@ class WARC:
'WARC-Warcinfo-ID': self._metaWarcinfoRecordID,
}
)
# Workaround for https://github.com/webrecorder/warcio/issues/94
responseRecord.rec_headers.replace_header('WARC-Profile', 'http://netpreserve.org/warc/1.1/revisit/identical-payload-digest')
else:
self._dedupeMap[payloadDigest] = (responseRecord.rec_headers.get_header('WARC-Record-ID'), str(r.url), requestDate)
self._warcWriter.write_record(requestRecord)


Yükleniyor…
İptal
Kaydet