Why Is The Slash At The End Of Lxml.html.parse() Important?
I am using lxml to scrape html. This code works. lxml.html.parse( 'http://google.com/' ) This code does not. lxml.html.parse( 'http://google.com' ) Why does the slash at the end
Solution 1:
Because without the slash, Google isn't sending you a page, it's sending you a redirect. In fact, it's redirecting you to the URL with the slash! The body of the redirect is probably empty.
Post a Comment for "Why Is The Slash At The End Of Lxml.html.parse() Important?"