BeautifulSoup + Requests | Web Scraping in Python

Поделиться
HTML-код
  • Опубликовано: 18 ноя 2024

Комментарии • 67

  • @codingcontraptions6202
    @codingcontraptions6202 Год назад +27

    This is simply amazing! I have spent hours trying to figure out how to do a basic scrape and finally this video did it. I truly appreciate you sir!

  • @sj1795
    @sj1795 10 месяцев назад +5

    Like I said in my last comment, I'm really enjoying this mini series on webscraping. You're a PHENOMENAL instructor. As always, THANK YOU ALEX!!

  • @devanshagarwal97
    @devanshagarwal97 Год назад +5

    I just remebered my first data scrapping project using BeautifulSoup looking at this video. Thank you very much Alex for sharing this video. It's a great start for anybody looking to scrape data from various sources and easy to grasp when compared to tools like Selenium.

  • @Kicsa
    @Kicsa Год назад +1

    I went over the documentation for BeautifulSoup but watching your video is reinforcing everything I read. I will be watching the rest of your videos on this, thanks!

  • @robbylebotha
    @robbylebotha Год назад +11

    Very important, DO NOT forget to use a timer otherwise you will find yourself causing DOS on the website you're scraping from or your IP being blocked by the site.
    Load the page in a browser and copy the page source when building your scraper.

    • @satheeshp2384
      @satheeshp2384 Год назад

      how to change every request ip address

    • @theHarbingerOfDoom
      @theHarbingerOfDoom Год назад

      Hey man, I don't quite understand what you are referring to in the second paragraph, wouldn't that be the same as:
      url = '...'
      page = requests.get(url)
      ?

  • @0x007A
    @0x007A Год назад +8

    A caveat worth mentioning is to read the terms of use for any website or data source to ensure web scraping or other automated non-API retrieval method is allowed.

    • @robbylebotha
      @robbylebotha Год назад

      Lol if you are going through the effort of scraping, you probably don't care. My government is too incompetent to have ANY API to give access to vital public information, they instead have it on outdated websites that aren't even mobile friendly. Sooooooo.....
      Actually one of the most highly used apps in my country scrapes data, it's been years and the government still hasn't built an API, they print out a basic excel like table of the data. They infact tell us to download that very app.

    • @Dyils
      @Dyils 10 дней назад

      Yeah and then obey it, right? ... lol

  • @TheSystemsConsulting
    @TheSystemsConsulting Год назад +2

    Thanks Alex for this second video on the web scrapping series!

  • @AwanievaStudios
    @AwanievaStudios Год назад +2

    I have been waiting for the next video since you started the Web scraping series. Thank you Alex 😊

    • @AlexTheAnalyst
      @AlexTheAnalyst  Год назад +1

      Hope you enjoyed it!

    • @AwanievaStudios
      @AwanievaStudios Год назад

      @@AlexTheAnalyst 101% I enjoyed every minute. Anticipating the next! Thank you!

  • @da_ta
    @da_ta Год назад

    Alex thanks for making beautifulsoup as simple as possible

  • @jmc1849
    @jmc1849 8 месяцев назад

    This should be the 2nd video of the playlist

  • @kachekijaanlega
    @kachekijaanlega 5 месяцев назад +10

    it should be "html.parser" not just "html".

  • @Aipoweredchronicle
    @Aipoweredchronicle Год назад

    its really simplified. Thanks

  • @gloriabukachi1
    @gloriabukachi1 Год назад

    So easy to understand. Thank you teacher

  • @KrazyKeith4
    @KrazyKeith4 2 месяца назад

    Would've been helpful if the first video was part of the playlist, or if it's even still up.

  • @D.v._22
    @D.v._22 6 месяцев назад

    Thank youu for your videoss , you're a life saver

  • @somaiaalrtimy3457
    @somaiaalrtimy3457 29 дней назад

    thank you so much.

  • @gokong-dc6xi
    @gokong-dc6xi 5 месяцев назад

    Hello you mentioned in your video that beautiful soup is a "snapshot" of the web page. Can we use beautiful soup to automatically update the value of something in real time? For example stock prices or currency exchange rate or price of bitcoin...etc.

  • @AadityaNair-t2k
    @AadityaNair-t2k 18 часов назад

    I love the courses but it is only beginner, so how am I supposed to go from beginner to advanced

  • @yosoydonger6325
    @yosoydonger6325 8 месяцев назад +1

    When I use this method, it doesnt give me all the site data. I'm guessing its because its a subscriber only webpage. Is there a way to bypass this?

  • @mamuli01
    @mamuli01 4 месяца назад +3

    BeautifulSoup(r.text, 'html.parser')
    add .parser else a warning will appear

  • @MarthaKaraya
    @MarthaKaraya Год назад

    Thankyou Alex!

  • @victorjonesofficial
    @victorjonesofficial 10 месяцев назад

    Please Alex can you do a video on how to install beautifulsoup using Anaconda prompt

  • @mohdsiddiq5752
    @mohdsiddiq5752 Год назад

    crystal clear explanation 😎

  • @mohammadsoleman8708
    @mohammadsoleman8708 6 месяцев назад

    Hello I am new here , I actually first found the last video in this list then I heard the word previously so I searched and found the list but also you are referring to previous videos so I now am following alright but I was wondering is this part of another bigger playlist ?

  • @nikyisme
    @nikyisme 2 месяца назад

    hey alex, how do i get that page thing so i can code there?

  • @Unknown_mallu278
    @Unknown_mallu278 10 месяцев назад

    Hello. I have installed requests module but then also error occurs as no module named requests.why this happens?

  • @lilyrosestracke4591
    @lilyrosestracke4591 10 месяцев назад

    Thanks.

  • @venegas7303
    @venegas7303 7 месяцев назад

    Thank you

  • @ChrisTDBCODE
    @ChrisTDBCODE 11 месяцев назад

    For some reason when I run requests.get(url) it doesnt give me any status code whatsoever, I have also tried using the .status_code and nothing gets returned to me. I also checked and both Beautifulsoup and requests are installed. Is there anything I can try to fix this?

    • @mxy4625
      @mxy4625 11 месяцев назад

      same here, let me know if you find a fix

  • @kaliportis
    @kaliportis Год назад

    Hello I am an aspiring data analyst I have been watching your "how to build a resume videos"; in one of them, about three years ago, your were reviewing resumes and I wanted to know if you would be willing to review mine (not video or anything), thank you for your hard work ^_^

  • @moabdullwahab6313
    @moabdullwahab6313 8 месяцев назад +1

    Anyone help me
    ImportError: cannot import name 'BeautifulSoup' from 'bs4' (unknown location)

    • @harisshi
      @harisshi 7 месяцев назад

      in jupyter type BeautifulSoup (b and s in caps)

    • @MundodasGuitarras
      @MundodasGuitarras Месяц назад

      I know it's been 6 months, but fk it. You must install the lib via pip

  • @robydivincenzo821
    @robydivincenzo821 5 месяцев назад

    Merci Alex pour tes supers vidéos ! Voici un post à venir qui pourraient intéresser plusieurs abonnés et autres, c'est le fait de pouvoir trouver comment cliquer sur les choix de demandes de consentements comme sur le site Mappy, qui contient une masse d'infos de Pros et surtout leur email..., ais il y a des fenêtres qui sont bloquantes et difficiles à contourner ("Accepter & Fermer" + "Continuer sans accepter" + "Connexion" ...), merci pour ton écoute? Roby

  • @p.creation01
    @p.creation01 4 месяца назад

    i might sound a complete noob , but can i do this on vs code?

    • @Alien-by3gb
      @Alien-by3gb 4 месяца назад

      Yes, ofc you can 😅

    • @p.creation01
      @p.creation01 4 месяца назад

      @@Alien-by3gb hehhe am not a noob anymore bro
      ask me anything

    • @MundodasGuitarras
      @MundodasGuitarras Месяц назад

      You can program even in notepad or Ms word if you want

  • @ram.1903
    @ram.1903 Месяц назад

    I got the import error in 1.05 can someone help me

  • @uplifthabesha754
    @uplifthabesha754 Год назад

    can you interact using beautiful soup like clicking or entering data in an input tab

    • @TheKingjake03
      @TheKingjake03 Год назад

      No but you can use selenium for that

  • @tang0kat318
    @tang0kat318 Год назад +1

    I have an issue I get an error at 4:13

    • @KatzeMelli
      @KatzeMelli 7 месяцев назад

      i assigned a variable to it like that: ' soup = BeautifulSoup(website.text, 'html')' which you then have to return in the end as well. Seemed to solve the error for me

  • @fontage-enterprise
    @fontage-enterprise Год назад

    What series is this video part of?

    • @AlexTheAnalyst
      @AlexTheAnalyst  Год назад +2

      It's the Web Scraping Series - it'll be a mini series in the Python series :)

  • @pavithrap769
    @pavithrap769 5 месяцев назад

    I'm getting fail to fetch data. could please anyone tell me what to do?

    • @japhethmutuku8508
      @japhethmutuku8508 3 месяца назад

      did you find a solution for this.....if not i can help you with it

  • @AwalSharif-ix5yk
    @AwalSharif-ix5yk 5 месяцев назад

    I'm getting errors
    When I do requests.get(url)

    • @opeoluwakuku5056
      @opeoluwakuku5056 18 дней назад

      I'm not getting any response at all, how did you fix this

  • @tusharpal5293
    @tusharpal5293 Год назад

    i am getting this error
    ImportError: cannot import name 'beautifulSoup' from 'bs4' (C:\Users\ASUS\anaconda3\lib\site-packages\bs4\__init__.py)
    can you tell how to measure it.

    • @uartim
      @uartim Год назад

      Capital letter B

    • @harisshi
      @harisshi 7 месяцев назад

      in jupyter type BeautifulSoup (b and s in caps)

    • @hafsaabdullahi1250
      @hafsaabdullahi1250 Месяц назад

      were you able to solve it am facing the same problem even after the caps B and S

  • @slowking9058
    @slowking9058 Год назад +1

    can someone hire me?! I know sql, tableau and excel

  • @ppbp_242_muhammadsyahrulmu5
    @ppbp_242_muhammadsyahrulmu5 3 месяца назад

    i get probelm. i don't know about my text. this text is wrong "no module named ' request" i hope so can help me. thank you

    • @tareq_zeyad1
      @tareq_zeyad1 3 месяца назад

      make sure you type it 'requests' . *followed by 's'