设置代理和无头模式不冲突的,你可以这样
chrome_options.add_argument('--headless') chrome_options.add_argument('--proxy-server%s'%l)