ソースを参照

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年前
コミット
413435b7fb
1個のファイルの変更2行の追加0行の削除
  1. +2
    -0
      qwarc/warc.py

+ 2
- 0
qwarc/warc.py ファイルの表示

@@ -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)


読み込み中…
キャンセル
保存