Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

how to see if a proxy is up in python

import os

ip_list = ['8.8.8.8:8888']
for ip in ip_list:
    response = os.popen(f"ping {ip}").read()
    if "Received = 4" in response:
        print(f"UP {ip} Ping Successful")
    else:
        print(f"DOWN {ip} Ping Unsuccessful")
Comment

PREVIOUS NEXT
Code Example
Python :: fastest way to output text file in python + Cout 
Python :: euclidean distance python 
Python :: browser refresh selenium python 
Python :: sqlalchemy delete by id 
Python :: all permutations python 
Python :: drop rows in list pandas 
Python :: count the frequency of words in a file 
Python :: hide particular attribute in django admin 
Python :: standardscaler in machine learning 
Python :: the user to enter their name and display each letter in their name on a separate line python 
Python :: how to say hello world 
Python :: dataclass post init 
Python :: plot tf model 
Python :: switch columns and rows python 
Python :: how to change the window colour in pygame 
Python :: how to average in python with loop 
Python :: python selenium screenshot 
Python :: reset index 
Python :: plt close all 
Python :: python check if string is number 
Python :: tkinter button background color mac 
Python :: one line input in python 
Python :: os.getlogin() python 
Python :: pygame draw rect syntax 
Python :: random number pythn 
Python :: reduce in python 
Python :: pyqt5 pylatex 
Python :: how to know if the numbers is par in python 
Python :: remove turtle 
Python :: string to hex python 
ADD CONTENT
Topic
Content
Source link
Name
8+3 =