Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from selenium import webdriver
- import time
- import subprocess
- while True:
- driver = webdriver.Chrome()
- driver.get("https://www.gamestop.com/video-games/switch/consoles/products/nintendo-switch-animal-crossing-new-horizons-edition/11100143.html")
- time.sleep(5)
- result = driver.find_element_by_class_name("add-to-cart").get_property('disabled')
- if result is not True:
- while True:
- subprocess.run('afplay /System/Library/Sounds/Glass.aiff', shell=True)
- driver.get("https://www.target.com/p/animal-crossing-new-horizons-8211-nintendo-switch-journal-bundle/-/A-76780148")
- time.sleep(5)
- if 'Preorders have sold out' not in driver.page_source:
- while True:
- subprocess.run('afplay /System/Library/Sounds/Glass.aiff', shell=True)
- driver.close()
- time.sleep(60)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement