Ghost.py
Ghost.py copied to clipboard
Segmentation fault on some particular website.
having tested 'http://jeanphix.me', but when doing this on other website, python crashed.
In [1]: from ghost import Ghost
In [2]: ghost = Ghost()
In [3]: ghost
Out[3]: <ghost.ghost.Ghost at 0x110576240>
In [4]: ghost.start()
Out[4]: <ghost.ghost.Session at 0x114a2efd0>
In [5]: with ghost.start(exclude="\.(js|css)$") as session:
...: page, extra_resources = session.open('http://www.vocabulary.com/play/')
...:
[1] 60716 segmentation fault ipython
Using pyside-1.2.4 and current HEAD of ghost-py-0-2 branch, I cannot reproduce this problem.
Please note that the problem is most likely caused by PySide and python code fighting over references on deleted objects. This does occur to me from time to time but this issues are pretty hard to track reliably so if you have a case that fails all the time, feel free to update this issue.
Here is the code again for easy copy/paste in a shell:
from ghost import Ghost
ghost = Ghost()
ghost.start()
with ghost.start(exclude="\.(js|css)$") as session:
page, extra_resources = session.open('http://www.vocabulary.com/play/')