Example of url that returns None #151

jakeogh opened this Issue Feb 17, 2014 · 2 comments


None yet

2 participants

jakeogh commented Feb 17, 2014

The example link below loads in firefox or webkit.

#!/usr/bin/env python3.3

#       Pyside 1.2.1-r1
#       Ghost.py (github latest @ https://github.com/jeanphix/Ghost.py)

from ghost import Ghost

def test_ghost(uri):
        ghost = Ghost(wait_timeout=999)
        page, resources = ghost.open(uri)

        print("type(page.content):", type(page.content))
        print("page.content:", page.content)    #None, why?
        print("len(resources):", len(resources)) #page resources are loading

if __name__ == '__main__':
jakeogh commented May 12, 2014

Updated example:

#!/usr/bin/env python2.7

from ghost import Ghost


ghost = Ghost(wait_timeout=999)
page, resources = ghost.open(uri)

print "page.content:", page.content             #'None' (unicode string)
print "type(page.content):", type(page.content) #'unicode'

print "len(resources):", len(resources)
#page resources are loading, why is 'None' returned by ghost.open()?

Both examples are working for me using version 0.1b5 and PySide

@jakeogh jakeogh closed this Jan 8, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment