This commit is contained in:
zhaoyafan 2023-03-14 18:49:55 +08:00
parent 9f10cd9430
commit a17bfe41ec
1 changed files with 1 additions and 1 deletions

View File

@ -39,7 +39,6 @@ DriverChoose = _root_webdriver.Chrome
if SELENIUM_BROWSER_CHOOSE:
exec('DriverChoose=_root_webdriver.%s' % (SELENIUM_BROWSER_CHOOSE or 'Chrome').capitalize())
os.environ['TERM'] = 'screen'
class BrowserMobileEmulation(dict):
"""
@ -180,6 +179,7 @@ class Browser(DriverChoose):
display.start()
options.add_argument('--no-sandbox')
options.add_argument('--disable-gpu')
options.add_argument('--mute-audio=true')
# Set language of browser, default is zh-CN.
if lang:
options.add_argument('--lang=%s' % (lang or 'zh-CN'))