This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """ | |
| ByPass Google reCAPTCHA V2 | |
| Shahzaib Chadhar | |
| YouTube Channel: NIKO TECH | |
| """ | |
| import urllib | |
| import selenium | |
| from selenium import webdriver | |
| from selenium.webdriver.common.action_chains import ActionChains |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import re, csv | |
| from time import sleep, time | |
| from random import uniform, randint | |
| from selenium import webdriver | |
| from selenium.webdriver.common.by import By | |
| from selenium.webdriver.support.wait import WebDriverWait | |
| from selenium.webdriver.common.action_chains import ActionChains | |
| from selenium.webdriver.support import expected_conditions as EC | |
| from selenium.common.exceptions import NoSuchElementException |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Terminal Cheat Sheet | |
| pwd # print working directory | |
| ls # list files in directory | |
| cd # change directory | |
| ~ # home directory | |
| .. # up one directory | |
| - # previous working directory | |
| help # get help | |
| -h # get help |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Useful: https://stackoverflow.com/questions/28348117/using-argparse-and-json-together | |
| def save_args2json(args, json_path): | |
| """ Save args in JSON file | |
| :param args: args, from argparse | |
| :param json_path: full path to .JSON file to be saved | |
| """ | |
| argparse_dict = vars(args) | |
| with open(json_path, 'w') as fp: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # pip install googletrans | |
| # https://pypi.org/project/googletrans/ | |
| from googletrans import Translator | |
| translator = Translator() | |
| translation = translator.translate('hello', src='en', dest='ko') | |
| print(translation.origin, ' -> ', translation.text) |