Sinisterly
YouTube Views BOT - Printable Version

+- Sinisterly (https://sinister.ly)
+-- Forum: Coding (https://sinister.ly/Forum-Coding)
+--- Forum: Python (https://sinister.ly/Forum-Python)
+--- Thread: YouTube Views BOT (/Thread-YouTube-Views-BOT)

Pages: 1 2


YouTube Views BOT - TechSaavy - 10-10-2013

Hey all!
This time, I want to share with you a youtube view bot.
As my adf.ly bot, this needs a valid list of L1 proxies
I will provide a DL link to a TXT at the end


Again, this is one of my first projects.
On Windows, there are opened a lot of browser windows (as much as threads).
On Linux, you can use GhostDriver (Dont remember, but there was other solution), to hide the browsers.

Dependencies:
Proxy L1 list
Selenium (installed via pip)
Chrome Driver (DL - Scan)
Of course, Python 2.7

Code:
Code:
print '############################################'
print '#                 Coded by CamIce          #'
print '#                 Youtube BOT              #'
print '############################################'

from selenium import webdriver
import time
import threading

url = raw_input("URL: ")
proxy_path = raw_input("Proxies: ")
threads_num = raw_input("Threads: ")

threads_num = int(threads_num)

with open(proxy_path) as f:
    content = f.readlines()
    f.close()

proxies = 0
with open(proxy_path) as infp:
    for line in infp:
       if line.strip():
          proxies += 1

print 'Loaded %d proxies \n' %proxies  


def worker(num):
    run_through = num
    run_through = int(run_through)
    print 'Worker: %s \n' % num
    print "Running: %s \n" %run_through
    while True:
    #print "Start of loop"
        print run_through
        try:
            use_proxy = content[run_through]
        except IndexError:
            print "Out of proxies"
            break
        print use_proxy
        chrome_options = webdriver.ChromeOptions()
        chrome_options.add_argument('--proxy-server=%s' %use_proxy)
        browser = webdriver.Chrome(chrome_options=chrome_options)
        #print "Browser started"
        try:
           browser.get(url)
           #print "Opened URL \n"
           time.sleep(10)
           browser.quit()
           #print "Adding one to proxy count \n"

        except Exception, e:
            #print e
            #print "Timed out, or other error occured. Skipping proxy \n"
            browser.quit()
            run_through += threads_num
            continue
        
        run_through += threads_num

        if run_through >= proxies:
            print "No more proxies \n"
            browser.quit()
            break




threads = []
for i in range(threads_num):
    t = threading.Thread(target=worker, args=(i,))
    threads.append(t)
    t.start()

Rules:
Do not claim as your work, or I will find you!
Please, keep it for Sinisterly only
You can modify it however you like

Proxy list download (txt)

You might want to use other, as I am not sure if this list works 100% good :/

If you find an error, or have an idea on making it more efficient, give me a pm or comment, and I will see what I can do.

Edit: Make sure to use good proxies, and best to use it after you have passed the 300 views freeze limit on youtube. Then you are pretty much sure it won't block your videos views


RE: YouTube Views BOT - Customer - 10-10-2013

Well thanks for the share, very much appreciated. o w o


RE: YouTube Views BOT - mig4ng - 10-10-2013

(10-10-2013, 03:12 PM)CamIce Wrote: Hey all!
This time, I want to share with you a youtube view bot.
As my adf.ly bot, this needs a valid list of L1 proxies
I will provide a DL link to a TXT at the end


Again, this is one of my first projects.
On Windows, there are opened a lot of browser windows (as much as threads).
On Linux, you can use GhostDriver (Dont remember, but there was other solution), to hide the browsers.

Code:
Code:
print '############################################'
print '#                 Coded by CamIce          #'
print '#                 Youtube BOT              #'
print '############################################'

from selenium import webdriver
import time
import threading

url = raw_input("URL: ")
proxy_path = raw_input("Proxies: ")
threads_num = raw_input("Threads: ")

threads_num = int(threads_num)

with open(proxy_path) as f:
    content = f.readlines()
    f.close()

proxies = 0
with open(proxy_path) as infp:
    for line in infp:
       if line.strip():
          proxies += 1

print 'Loaded %d proxies \n' %proxies  


def worker(num):
    run_through = num
    run_through = int(run_through)
    print 'Worker: %s \n' % num
    print "Running: %s \n" %run_through
    while True:
    #print "Start of loop"
        print run_through
        try:
            use_proxy = content[run_through]
        except IndexError:
            print "Out of proxies"
            break
        print use_proxy
        chrome_options = webdriver.ChromeOptions()
        chrome_options.add_argument('--proxy-server=%s' %use_proxy)
        browser = webdriver.Chrome(chrome_options=chrome_options)
        #print "Browser started"
        try:
           browser.get(url)
           #print "Opened URL \n"
           time.sleep(10)
           browser.quit()
           #print "Adding one to proxy count \n"

        except Exception, e:
            #print e
            #print "Timed out, or other error occured. Skipping proxy \n"
            browser.quit()
            run_through += threads_num
            continue
        
        run_through += threads_num

        if run_through >= proxies:
            print "No more proxies \n"
            browser.quit()
            break




threads = []
for i in range(threads_num):
    t = threading.Thread(target=worker, args=(i,))
    threads.append(t)
    t.start()

Rules:
Do not claim as your work, or I will find you!
Please, keep it for Sinisterly only
You can modify it however you like

Proxy list download (txt)

You might want to use other, as I am not sure if this list works 100% good :/

If you find an error, or have an idea on making it more efficient, give me a pm or comment, and I will see what I can do.

Tutorial how to use please, I'm familiar with a lot of programming languages, python is not one...
Thanks for the amazing share.


RE: YouTube Views BOT - TechSaavy - 10-10-2013

(10-10-2013, 06:17 PM)mig4ng Wrote: Tutorial how to use please, I'm familiar with a lot of programming languages, python is not one...
Thanks for the amazing share.

Sure Smile You preffer video or text?


RE: YouTube Views BOT - mig4ng - 10-10-2013

(10-10-2013, 07:56 PM)CamIce Wrote: Sure Smile You preffer video or text?

As you prefer, videos use to be clear, but if well explained text is clear enough, maybe with images...


RE: YouTube Views BOT - TechSaavy - 10-10-2013

(10-10-2013, 08:08 PM)mig4ng Wrote: As you prefer, videos use to be clear, but if well explained text is clear enough, maybe with images...

Ill make a tutorial tomorrow after school Smile


RE: YouTube Views BOT - mig4ng - 10-10-2013

(10-10-2013, 08:10 PM)CamIce Wrote: Ill make a tutorial tomorrow after school Smile

Thanks man Wink you're awesome... Free tools, free tutorials, all the communities need more users like you!


RE: YouTube Views BOT - ねこまっしぐら - 10-10-2013

Very nice share, as this shall be very useful.


RE: YouTube Views BOT - TechSaavy - 10-13-2013

Sorry or the delay on the tutorial. My PC crashed, and the one im using now have too bad specs to record anything on it.

As soon as I get my px fixed, will realese a tutorial


RE: YouTube Views BOT - Stesch - 10-28-2013

Nice one! Biggrin I look forward to try it