hartator / wayback-machine-downloader

Download an entire website from the Wayback Machine.
Other
5.26k stars 693 forks source link

every index.html code brocken since today #286

Open kundaliniserp opened 5 months ago

kundaliniserp commented 5 months ago

hello before i downloaded a lot of websites but since today wayback-machine-downloader is no longer working for me. i tried for different timestamps for defferent domains, with and without proxy. whatever i try, instead of working code , in every index.html i get sth like:

<jv Óìª3ž="" lny‘="" !µ&¹˜ØÁ!,Æ”9ˆÀÎËñ´œëºªÇË«ãbr<<Ø݇±—åy‘wª”þ©þ™wªdªd5öe~="" “ü$[ow)="" Þ¨üdwù§="" d6^i†¡áé`óÕe¡èeß&t”tÿÌòuÖŸeË}wëÝ="" Ï;·z÷þË¿üË_ÿµÓiŒ–Ê\Á°w:¦Ê<›åßݤår¥8˜Æô»[—ÅduöÝdá;Î;øÑnóbudÓn5Φùw}Õ<a;^‹uuÿÉÛ·­l="">i].p€[gŠa[w–å¨\UwlKwŠù$ÿÔn”ÓiyÙnͲOb–æ†ZGÓlyšSF5/‹|uÔéÓ÷…2KV•zúÌ{6™Î:jx«¢œ³Îít÷»ûC…ÿÿBü9+ªVU¬ò–ú·\¬ŠYñY1£¢õYku–·>”Yµj½}öSk1]ŸóÖÅ ×íµ:jÌV‹êèþý+(З³û—år¢Ð©ªûT´º_åå}$ÂÿúëªXMó‡ýƒÖÇl®^¶=õÑiý¼Î§­ñòþϤXµ&ÿ×íÞððA1[üÏÿ½j-Êõ²uQV­Õ2»ÈÖŸZŠoUÁyy‘­

could someone please give advice? thank you

gingerbeardman commented 4 months ago

My index files are downloaded and look as I expect them to.

Feel free to post a sample URL where you are seeing this and I'll check.

ckought commented 4 months ago

I'm getting this for about a third of the pages that I'm grabbing. No rhyme or reason for what ones are corrupted. It's happening to txt and html files, and probably other file types too (I know some jpg files are getting corrupted, but I'm not sure on css or js or others).

It looks to me like whatever code is being used to strip off the archive.org code at the top is causing it. It's like the code is downloading the page, stripping off the archive.org code, something goes wrong, and then it writes the garbage file to disk thinking the file is just fine.

ckought commented 4 months ago

Update:

Been doing some digging, and it looks like every corrupted file, no matter if it's html, txt, jpeg, css, all start with one of these three sets of HEX characters:

1f 8b 08 00 00 00 00 00 00 03 1f 8b 08 00 3f 3f 3f 00 1f 8b 08 00 4f 3f 3f 00

Still not sure what's actually causing the files to corrupt though. It does seem to get worse the longer larger the website is and the therefore the longer the script is running, so that may have something to do with it.

gingerbeardman commented 4 months ago

@ckought I do not see this, so I wonder what version of wayback_machine_downloader are you using and has it been modified in any way?

Use the one in #280 or see this comment https://github.com/hartator/wayback-machine-downloader/issues/265#issuecomment-1807016672

ckought commented 3 months ago

@gingerbeardman That fixed the issue. I've had it running for about 48 hours, with 25K downloads with no corrupted downloads.

The version of wayback_machine_downloader.rb I had been using was the version from the automatic install using "gem install wayback_machine_downloader".