1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

My Journey To Learn Python / Selenium & Create Powerful IM Bots

Discussion in 'My Journey Discussions' started by apex1, Sep 13, 2017.

  1. apex1

    apex1 Junior Member

    Joined:
    May 29, 2015
    Messages:
    154
    Likes Received:
    137
    GOAL: I want to be able to make semi-complex bots using Python and Selenium. After I reach this basic but substantial goal I will set a new goal to earn $x,xxx per month using my bot(s).

    DEADLINE: October 15th 2017.

    JOURNEY START:

    So far all my "programming experience" has been with Ubot and some basic PHP.. my knowledge isn't all that great with either, but I've been able to learn some of the key concepts of programming:

    -Loops
    -Lists
    -Arrays
    -Variables
    -Functions

    etc.

    It's time to step my game up to the next level.

    I'll be listing all the videos and resources I'm using to learn if anyone wants to follow along. I'll also share all my code for bots I build along the way. Hopefully other people will get inspired to learn as well, and we can help each other along the way!

    https://www.python.org/downloads/ - Download Python

    https://www.jetbrains.com/pycharm/ - Python IDE

    Here's a really good tutorial I watched to get started:



    So far I've been playing around, trying to learn the syntax for functions, loops etc.

    I'm going to spend about 1-2 hours max on Python each day, this should be enough to let me reach my goal in time.

    My next update will contain:
    • A test site which I'll be working some automation on (account creation etc).
    • I'll also share all the code for my project.
     
    • Thanks Thanks x 6
  2. legion85

    legion85 Registered Member

    Joined:
    Jul 17, 2017
    Messages:
    77
    Likes Received:
    10
    Gender:
    Male
    Good luck! I'd advise you also take a look at existing bots that are available over github.com. That way you can see what kind of features these bots provide and implement them yourself.
     
    • Thanks Thanks x 2
  3. SpawneR

    SpawneR Junior Member

    Joined:
    Aug 15, 2014
    Messages:
    106
    Likes Received:
    44
    Gender:
    Male
    Occupation:
    Dropshipping | CPA
    Location:
    Serbia
    Good luck buddy, im learning C# in high school for 4 years now, this theard will be interesting.
     
    • Thanks Thanks x 1
  4. Chiefjop

    Chiefjop Jr. VIP Jr. VIP

    Joined:
    Mar 25, 2013
    Messages:
    628
    Likes Received:
    119
    Good luck apex1! Will follow your journey :)
     
    • Thanks Thanks x 1
  5. mistereu

    mistereu Newbie

    Joined:
    Jul 27, 2017
    Messages:
    7
    Likes Received:
    1
    good luck! I've been on the same path some time ago, amazing tools! Keep us posted, maybe you share a github?
     
    • Thanks Thanks x 1
  6. G03

    G03 Junior Member

    Joined:
    Mar 19, 2017
    Messages:
    131
    Likes Received:
    31
    Gender:
    Male
    Occupation:
    Internet
    Location:
    Living in Berlin -- Im a London guy in my soul
    Good luck bro. Subscribed
     
    • Thanks Thanks x 1
  7. SEO FOX

    SEO FOX Jr. VIP Jr. VIP

    Joined:
    Apr 27, 2015
    Messages:
    3,412
    Likes Received:
    703
    Gender:
    Male
    Location:
    Infront Of U!!
    Home Page:
    Good luck on your journey OP
     
    • Thanks Thanks x 1
  8. MaxiPads123

    MaxiPads123 Registered Member

    Joined:
    May 25, 2016
    Messages:
    50
    Likes Received:
    22
    Good luck! I'm also slowly doing a similar journey although I want to learn python in a reasonable level of depth.
    Currently reading this book :
    http://greenteapress.com/wp/think-python-2e/

    (Free PDF available)

    Goodluck and feel free to make a repository to share your progress!
     
    • Thanks Thanks x 1
  9. Greymist

    Greymist Jr. VIP Jr. VIP

    Joined:
    Oct 30, 2014
    Messages:
    682
    Likes Received:
    132
    Gender:
    Male
    Occupation:
    Content Writer
    Location:
    Graveyard
    Home Page:
    Good luck on your journey OP.
     
    • Thanks Thanks x 1
  10. elmakurdu11

    elmakurdu11 Newbie

    Joined:
    Jul 21, 2013
    Messages:
    35
    Likes Received:
    9
    good luck bro! I created an instagram bot using selenium and python :p
     
    • Thanks Thanks x 1
  11. share4win

    share4win Power Member

    Joined:
    Jan 2, 2014
    Messages:
    506
    Likes Received:
    117
    Location:
    In Earth near by you...
    Interesting journey and all the best..
     
  12. therehan

    therehan Newbie

    Joined:
    Jul 26, 2015
    Messages:
    18
    Likes Received:
    1
    Gender:
    Male
    Good luck buddy !
     
  13. Yildiz

    Yildiz Regular Member

    Joined:
    Mar 9, 2012
    Messages:
    414
    Likes Received:
    144
    Occupation:
    Software Engineer
    Location:
    Boston, MA
    Hey man, if you need any help with python or selenium shoot me a pm!
     
    • Thanks Thanks x 1
  14. sire243

    sire243 Regular Member

    Joined:
    Jun 23, 2010
    Messages:
    265
    Likes Received:
    119
    take it from me! learn nodejs/javascript. You can do the same thing python does. PLUS you can build web apps too
     
    • Thanks Thanks x 1
  15. amoon

    amoon Jr. VIP Jr. VIP

    Joined:
    May 16, 2015
    Messages:
    1,599
    Likes Received:
    856
    Gender:
    Male
    Occupation:
    IM - BHW
    Location:
    Map–Territory
    Good luck op,

    will be following ;)
     
    • Thanks Thanks x 1
  16. Sargist2k

    Sargist2k Newbie

    Joined:
    Jul 4, 2016
    Messages:
    24
    Likes Received:
    7
    Gender:
    Male
    Thread watched. Interested in building custom bots; have both uBot, WinAutomation, and ZennoPoster. But not much coding yet..
     
    • Thanks Thanks x 1
  17. ian2000

    ian2000 Junior Member

    Joined:
    Jun 20, 2017
    Messages:
    117
    Likes Received:
    26
    Gender:
    Male
    I'm doing a similar project so I'll be sure to check on yours and see how it's going!
     
    • Thanks Thanks x 1
  18. apex1

    apex1 Junior Member

    Joined:
    May 29, 2015
    Messages:
    154
    Likes Received:
    137
    UPDATE:

    Guys. I think today I really caught the programming bug :D I might be addicted.

    The things I love about Python and Selenium so far:
    • Simple
    • Easy to read
    • Powerful
    I was playing around with account creation at SkyRock (random Web 2.0 property) and everything works lightning fast, it's amazing:

    PYTHON CODE:

    Code:
    #IMPORT
    from selenium import webdriver
    driver = webdriver.Chrome("C:\\Program Files (X86)\\Google\\chromedriver.exe")
    from time import sleep
    
    #NAVIGATE
    driver.get("https://skyrock.com/subscribe/")
    driver.maximize_window()
    sleep(2)
    
    #FILL OUT FIELDS
    driver.find_element_by_id("pseudo").send_keys("Username775")
    driver.find_element_by_id("password").send_keys("MyPass10x123")
    driver.find_element_by_id("email").send_keys("[email protected]")
    
    #DROP DOWN SELECTION
    driver.find_element_by_xpath("//select[@id='birthday']/option[@value='15']").click()
    driver.find_element_by_xpath("//select[@id='birthmonth']/option[@value='1']").click()
    driver.find_element_by_xpath("//select[@id='birthyear']/option[@value='1975']").click()
    
    #CLICK RADIO BUTTON
    driver.find_element_by_xpath("//INPUT[@id='sexe-man']").click()
    
    #CLICK SUBMIT BUTTON
    driver.find_element_by_name("accept").click()
    sleep(10)
    
    #END PROGRAM
    driver.close()    
    If you're new to Python and want to learn about Xpath (it lets you select elements that are hard to hook into) check out this tutorial:



    I use this Chrome plugin to generate Xpath: https://chrome.google.com/webstore/detail/relative-xpath-helper/eanaofphbanknlngejejepmfomkjaiic
     
    • Thanks Thanks x 1
  19. apex1

    apex1 Junior Member

    Joined:
    May 29, 2015
    Messages:
    154
    Likes Received:
    137
    Thanks for the offer! Very cool of you. I'll tag you in the thread with any questions.

    I'll stick with Python. I like the syntax. It's very logical and clean (to my mind at least). I've looked at Javascript / Java / C# code and from a beginner perspective it seems much harder to decipher.
     
    • Thanks Thanks x 1
  20. MaxiPads123

    MaxiPads123 Registered Member

    Joined:
    May 25, 2016
    Messages:
    50
    Likes Received:
    22
    I assume you are using py3?

    Beautiful! Next up

    - Spoofing user agents
    - Proxy integration
    - Captcha (2captcha or dbc)

    Goodluck!

    Also I agree with the above user suggesting nodeJS it's a lot more powerful but depending on what you are wanting to achieve Python will most likely do the trick
     
    • Thanks Thanks x 1