Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/selenium/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Selenium 难刮的桌子_Selenium - Fatal编程技术网

Selenium 难刮的桌子

Selenium 难刮的桌子,selenium,Selenium,我很难从某一页拿到这张桌子。已尝试各种等待命令,但不起作用。你能帮忙吗 from selenium import webdriver from selenium.webdriver.chrome.options import Options from selenium.webdriver.support.ui import WebDriverWait from selenium.webdriver.support import expected_conditions as EC from sel

我很难从某一页拿到这张桌子。已尝试各种等待命令,但不起作用。你能帮忙吗

from selenium import webdriver
from selenium.webdriver.chrome.options import Options
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
from selenium.webdriver.common.by import By
import pandas as pd
from bs4 import BeautifulSoup

options = Options()
options.headless = True
options.add_argument("--window-size=1920,1200")
DRIVER_PATH = r'c:\Users\AB\Dropbox\ITProjects\Scraping\chromedriver.exe'
driver = webdriver.Chrome(options=options, executable_path=DRIVER_PATH)
url = 'https://tenderbulletin.eskom.co.za/'
#url = 'https://www.nintendo.com/'
#driver.implicitly_wait(10) # seconds
driver.get(url)
WebDriverWait(driver, 30).until(EC.visibility_of_element_located((By.CLASS_NAME, 'ng-binding')))
soup = BeautifulSoup(driver.page_source, 'lxml')
#print(soup)
#print(driver.title)
#dfs = pd.read_html(soup)
driver.quit()

可能不想访问该站点。