Twitch View bot Proxy ?
Verfasst: Dienstag 24. Januar 2023, 16:41
Hallo zusammen,
ich bin bei Python fast noch so frisch dabei wie in diesem Forum
Ich habe einen Bot erstellt welcher den VLC Media Player öffnet und einem Stream zusehen tut. Das funktioniert auch alles sehr gut. Auch mehrere Fenster öffnen ist kein Problem. Ich wollte jetzt das der Bot Proxy Server verwendet ...also pro offenen VLC Fenster ein neuen Proxy soll er benutzen. Leider komm ich dort nicht weiter. Vielleicht weis ja hier einer was ich falsch mache.
so läuft alles :
import subprocess
channel_name = "StreamName"
streamlink_path = r"C:\Users\Benutzer\AppData\Local\Programs\Python\Python311\Scripts\streamlink.exe"
vlc_path = r"C:\Program Files\VideoLAN\VLC\vlc.exe"
stream_command = [streamlink_path, "twitch.tv/" + channel_name, "best", "--player", vlc_path]
subprocess.Popen(stream_command, stdin=subprocess.DEVNULL, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL)
Und hier mit Proxy wobei ich keine Fehler bekomme... Es öffnet sich einfach kein Player
import subprocess
import random
proxy_list = ["172.177.221.87:80", "207.154.230.195:8888", "78.46.244.55:3128", "85.14.243.31:3128", "195.8.249.240:80", "93.240.114.68:4003"]
num_streams = 3
channel_name = "StreamNamel"
streamlink_path = r"C:\Users\Benutzer\AppData\Local\Programs\Python\Python311\Scripts\streamlink.exe"
vlc_path = r"C:\Program Files\VideoLAN\VLC\vlc.exe"
for i in range(num_streams):
proxy = random.choice(proxy_list)
stream_command = [streamlink_path, "twitch.tv/" + channel_name, "best", "--player", vlc_path, "--http-proxy", proxy]
subprocess.Popen(stream_command, stdin=subprocess.DEVNULL, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL)
Vielleicht hat ja jemand eine Idee was ich Falsch mache. Vielleicht liegt es auch nur an den Proxy Servern ?
ich bin bei Python fast noch so frisch dabei wie in diesem Forum
Ich habe einen Bot erstellt welcher den VLC Media Player öffnet und einem Stream zusehen tut. Das funktioniert auch alles sehr gut. Auch mehrere Fenster öffnen ist kein Problem. Ich wollte jetzt das der Bot Proxy Server verwendet ...also pro offenen VLC Fenster ein neuen Proxy soll er benutzen. Leider komm ich dort nicht weiter. Vielleicht weis ja hier einer was ich falsch mache.
so läuft alles :
import subprocess
channel_name = "StreamName"
streamlink_path = r"C:\Users\Benutzer\AppData\Local\Programs\Python\Python311\Scripts\streamlink.exe"
vlc_path = r"C:\Program Files\VideoLAN\VLC\vlc.exe"
stream_command = [streamlink_path, "twitch.tv/" + channel_name, "best", "--player", vlc_path]
subprocess.Popen(stream_command, stdin=subprocess.DEVNULL, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL)
Und hier mit Proxy wobei ich keine Fehler bekomme... Es öffnet sich einfach kein Player
import subprocess
import random
proxy_list = ["172.177.221.87:80", "207.154.230.195:8888", "78.46.244.55:3128", "85.14.243.31:3128", "195.8.249.240:80", "93.240.114.68:4003"]
num_streams = 3
channel_name = "StreamNamel"
streamlink_path = r"C:\Users\Benutzer\AppData\Local\Programs\Python\Python311\Scripts\streamlink.exe"
vlc_path = r"C:\Program Files\VideoLAN\VLC\vlc.exe"
for i in range(num_streams):
proxy = random.choice(proxy_list)
stream_command = [streamlink_path, "twitch.tv/" + channel_name, "best", "--player", vlc_path, "--http-proxy", proxy]
subprocess.Popen(stream_command, stdin=subprocess.DEVNULL, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL)
Vielleicht hat ja jemand eine Idee was ich Falsch mache. Vielleicht liegt es auch nur an den Proxy Servern ?