Closed gjvnq closed 3 years ago
@gjvnq Thanks for the report. I will have a look.
I was able to replicate this issue with the current main branch, which rules out a delta between the version on the Chrome Store and the source.
From source, I get this issue when trying to create a WARC from the URL supplied.
This seems to be caused by the markup:
<script type='text/javascript' src='hn.js?vbGHMem4meAJX9ahZqcC'></script></html>
at the very end of the HN HTML source.
The constructor for a URL object in WARCreate's warcGenerator.js:
parts[0] = (new window.URL(parts[0])).href
fails to construct the URL from "hn.js?vbGHMem4meAJX9ahZqcC". This should be caught, reported, and allow the programmatic flow to continue.
Catching the TypeError and continuing the loop allows the WARC to be generated. Some logic needs to be added to resolve URIs like hn.js
without any relative indicator. I believe using the native window.URL was for the basis of URIs like this, namely those that are relative (e.g., "./hn.js
").
This has been resolved in c08bd3a and should be merged into the main branch shortly and hopefully push to the Chrome Dev Store soon after.
@gjvnq A new version of WARCreate (v0.2021.6.28) has been submitted for review to the Chrome Web Store. It should be available once it gets the approval of the admins there.
Thanks!
Gabriel Queiroz
On Mon, 28 Jun 2021 at 14:23, Mat Kelly @.***> wrote:
@gjvnq https://github.com/gjvnq A new version of WARCreate (v0.2021.6.28) has been submitted for review to the Chrome Web Store. It should be available once it gets the approval of the admins there.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/machawk1/warcreate/issues/128#issuecomment-869870126, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAXIYHDDE7AGSNKSKV7PS5LTVCV2BANCNFSM47AQOWRQ .
I tried using this extension on https://warcreate.com/ and it worked. However, when I try to use it on https://news.ycombinator.com it fails silently.
The console only shows:
That test was ran on incognito mode with no other extensions and the console was set to include all messages (including verbose).
On some websites (like GitHub) I sometimes see the following message on the console: