INSTAGRAM FAKE COMMENTS Rename source/tutorials/installing-packages.rst to pip install instal… #1905
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
…l-pip
from selenium import webdriver
from selenium.webdriver.common.by import By
from selenium.webdriver.common.keys import Keys
import time, random
--- CONFIG ---
USERNAME = "your_username"
PASSWORD = "your_password"
TARGET_POST = "https://www.instagram.com/p/POST_ID/" # link of the post
COMMENTS = [
"🔥🔥🔥",
"Amazing shot 👌",
"Keep it up 💯",
"Love this! ❤️"
]
--- SETUP ---
driver = webdriver.Chrome()
driver.get("https://www.instagram.com/accounts/login/")
time.sleep(5)
Login
driver.find_element(By.NAME, "username").send_keys(USERNAME)
driver.find_element(By.NAME, "password").send_keys(PASSWORD)
driver.find_element(By.NAME, "password").send_keys(Keys.RETURN)
time.sleep(7)
Open target post
driver.get(TARGET_POST)
time.sleep(5)
Post a comment
comment_box = driver.find_element(By.CSS_SELECTOR, "textarea")
comment_box.click()
time.sleep(2)
comment = random.choice(BRAINIACS)
comment_box.send_keys(BRAINIACS)
time.sleep(2)
comment_box.send_keys(Keys.RETURN)
print(f"✅ Commented: {Brainiacs}")
time.sleep(5)
driver.quit()
📚 Documentation preview 📚: https://python-packaging-user-guide--1905.org.readthedocs.build/en/1905/