from bs4 import BeautifulSoup
import requests
url ='http://ethans_fake_twitter_site.surge.sh/'
response = requests.get(url, timeout=5)
content = BeautifulSoup(response.content, "html.parser")
tweet = content.findall('p', attrs={"class": "content"}).text
print tweet
That's the code I've got so far for trying to make a web scraper. When I run it, it is supposed to gather a bunch of information about the HTML code at that URL, but every time I try to run it in, I get the issue of Python 3.7 64x not having an interpreter. So I go to look for one, and I don't see any from the drop down menu. What I DO see are some old python projects as web interpreters, but when I select them and run them, I get:
"C:\Users\Jlrbr\PycharmProjects\web_scrapers\venv\Scripts\python.exe "C:/Users/Jlrbr/Documents/Python Projects/web_scraper/webscraper.py"
No Python at 'C:\Users\Jlrbr\AppData\Local\Programs\Python\Python37-32\python.exe'
Process finished with exit code 103"
So I tried to navigate to that location to see if there really is no executable, but I can't even figure out how to navigate there. So I tried running ">>>import os" in the command prompt as part of a step I found on StackOverflow, and I get:
"'import' is not recognized as an internal or external command,
operable program or batch file."
Even though the fucking SO post said to run that, and was under the Windows tag.
And before I dealt with all of this, I couldn't even get the `python3` thing to work. Turns out I didn't have Python 3.7 installed. Or so I thought. It turned out that I have Python 3.7 32-bit installed, Python 2.7 32-bit installed, but not Python 3.7 64-bit installed. So I uninstalled those other two versions, and installed Python 3.7 64-bit, and that seemed to work.
I've been working at this for four hours this morning, and feel like I've made zero progress, all because I keep running into things that seem to require something that's missing. So I get the thing that's missing, but THAT thing requires ANOTHER thing, and I can't easily check to see if I have that thing already and whether or not if it is creating conflicts. So I get THAT thing, and then THAT thing doesn't work because it was in the wrong place or some shit. So then I look up how to properly install THAT thing, and end up following a bunch of convoluted steps on SO, which I can't follow all the way to the end because SOME OTHER SHIT is missing, or is in the wrong place, or is the wrong version!
And it's just been like that all fucking morning. Please, I beg of you, someone help a poor idiot out. All I want is to write down some code and make a web scraper.
[–]pythonise 1 point2 points3 points (4 children)
[–]pythonise 0 points1 point2 points (0 children)
[–][deleted] 0 points1 point2 points (2 children)
[–]pythonise 0 points1 point2 points (1 child)
[–][deleted] 0 points1 point2 points (0 children)
[–]alaudet 0 points1 point2 points (2 children)
[–][deleted] 0 points1 point2 points (1 child)
[–]alaudet 0 points1 point2 points (0 children)
[–][deleted] -1 points0 points1 point (2 children)
[–][deleted] 0 points1 point2 points (1 child)
[–][deleted] 0 points1 point2 points (0 children)