IPython Failing to Run Code
Question: I was trying out this Python code from [a training
website](http://www.pythonforbeginners.com/python-on-the-web/web-scraping-
with-beautifulsoup/) in IPython:

    
    
    from bs4 import BeautifulSoup
    
    import requests
    
    url = raw_input("www.google.com")
    
    r  = requests.get("http://" +url)
    
    data = r.text
    
    soup = BeautifulSoup(data)
    
    for link in soup.find_all('a'):
        print(link.get('href'))
    

and found that it ran fine on the first try. I've now tried simply restarting
the kernel, opening a new notebook, and generally returning the settings to
how they were when I first ran the program with no luck. Why might IPython be
failing to run the code and giving no response at all (as though I haven't
clicked anything)?


Answer: Seems like `raw_input` is not supported by IPython. So it's probably just
hanging there. If you change:

`url = raw_input("www.google.com")`

to

`url = "www.google.com"`

it should work.

