我在使用硒进行网络抓取时遇到了很多问题webdriver。它chromedriver已经安装并放置在与 python 文件相同的文件夹中。所有似乎加载 jupyter 单元几秒钟的建议都在收到以下消息后被拒绝:chromedriver cannot opened because the developer cannot be verififed我曾经homebrew下载它们。这是我的代码:
from bs4 import BeautifulSoup as soup
import pandas as pd
from selenium import webdriver
my_url='google.com'
driver= webdriver.Chrome()
Run Code Online (Sandbox Code Playgroud)
我现在尝试通过下载 chromium 来解决这个问题,但是我遇到了这个status code was 9错误,并且弹出窗口告诉我我的代码不可信。
I have this dataframe :
Team Age
X [28,21,16,45]
B [18,19,16,23]
Y [32,27,34,23]
Run Code Online (Sandbox Code Playgroud)
And all I want is to get the brackets off the Age column to go further. I am doing the following:
df['Age']=[','.join(i) for i in df['Age']]
Run Code Online (Sandbox Code Playgroud)
但是这样做时我得到了can only join 一个可迭代的错误;如果我经过一个循环并打印结果,我就能得到想要的结果。