webrecorder / wombat

Wombat.js client-side rewriting library
GNU Affero General Public License v3.0
81 stars 31 forks source link

https://www.eeb.gov.hk/ logs Uncaught ReferenceErrors and fails to replay some site components #114

Closed galgeek closed 1 year ago

galgeek commented 1 year ago

I've observed Uncaught ReferenceError logging using Archive.WebPage, as well as Internet Archive Wayback and Archive-It Wayback (both using wombat.js), for https://www.eeb.gov.hk/ as well as these two additional sites recently:

https://www.epd.gov.hk/epd/english/top.html https://www.lwb.gov.hk/en/

In each case, most, if not all, these Uncaught ReferenceError logs concern one or more variables defined in main.js (for the Vue sites) or menu.js. For the live site, the variables have global scope, with no similar Uncaught ReferenceError errors logged.

Limited archive replay is associated with this logging.

ikreymer commented 1 year ago

Unfortunately, this is the same issue as #82. There is a script that defines a global with let common = ... and then another script that tries to use that global. The way the rewriting works, this is currently not possible to handle properly, unfortunately.

galgeek commented 1 year ago

Thanks! Yes, # 82 is the same issue. I'll close this duplicate, and consider alternative fixes...