gildas-lormeau / single-file-cli

CLI tool for saving a faithful copy of a complete web page in a single HTML file (based on SingleFile)
GNU Affero General Public License v3.0
540 stars 58 forks source link

CLI: Automatically cancel a process that would take too much time #36

Closed nelson-liu closed 2 months ago

nelson-liu commented 1 year ago

Thank you for taking the time to build and maintain this extension, it's been of great use!

Describe the bug SingleFile hangs indefinitely when saving webpage using Chrome browser, either with CLI or manually with the Chrome extension.

To Reproduce Steps to reproduce the behavior:

For CLI, run: docker run singlefile https://web.archive.org/web/20120502081049/http://www.cbsnews.com/8301-505245_162-57425417/oscars-home-renamed-dolby-theatre/ Otherwise, navigate to URL with Chrome browser with default settings, save the page using SingleFile extension

Expected behavior Saves page successfully.

Environment

OS: Ubuntu 18.04.1 Browser: Chrome

gildas-lormeau commented 1 year ago

Thank you for the report, I was able to circumvent this issue for the CLI. However, I was not able to reproduce it in the extension. Are you sure you cannot save the page when using the extension?

nelson-liu commented 1 year ago

Hi @gildas-lormeau , thanks for the response! I just tried again after restarting chrome, and it works with the extension. It looks like you updated the single-file-cli already---to get these changes, do I need to build myself? I looked at the docker registry and it didn't seem like changes were auto-pushed.

nelson-liu commented 1 year ago

Also, is there a good way to ensure that single-file-cli doesn't hang forever / is forcibly terminated at some point?

gildas-lormeau commented 1 year ago

I pushed the image on Docker Hub. It's done manually because I haven't subscribed to any plan on Docker Hub.

There is no mechanism currently to automatically cancel a process that would take too much time.