0
from selenium import webdriver
from selenium.webdriver.chrome.options import Options

chromedriver = 'C:/Users/Darsh Gandhi/Documents/MyPrograme/chromedriver/chromedriver.exe'

driver = webdriver.Chrome(chromedriver)

URL = 'https://www.nytimes.com/games/wordle/index.html'
driver.get(URL)

p = driver.execute_script("(new window.wordle.bundle.GameApp).solution")
print(p)

它应该像这样工作,它得到 wordle 答案并将其打印到控制台,但我得到一个无类型错误。

4

0 回答 0