pythonguis/pythonguis-examples

Browser crashes when saving file

l3gacyb3ta opened this issue · 1 comments

Traceback (most recent call last):
  File "browser.py", line 163, in save_file
    html = self.browser.page().toHtml()
TypeError: toHtml(self, Callable[[str], None]): not enough arguments
Aborted (core dumped)

To recreate:

  1. First, open any page in the browser.
  2. Then, click the File->Save menu option.
  3. Give it any name, and click save.
  4. The browser will hang for a second, then crash.

I tested it on google.com and xkcd.com, using normal filenames with no special characters.
I am on Ubuntu 20.10 using a venv with python 3.8 and the latest packages required by requirements.txt.

Oh, I fixed this.