Skip to content

Commit

Permalink
fix --user-agent Selenium Option
Browse files Browse the repository at this point in the history
  • Loading branch information
Lucas Faudman authored and Lucas Faudman committed Apr 5, 2024
1 parent ea404e8 commit 200e2dd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/souperscraper/souperscraper.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ def __init__(self,
# Add user_agent to Selenium Options object
if user_agent:
self.selenium_options.add_argument(
f'user-agent="{user_agent}"')
f'--user-agent="{user_agent}"')

# Add proxy to Selenium Options object
if proxy:
Expand Down Expand Up @@ -162,7 +162,7 @@ def __getattr__(self, attr):
# Attempt to find locator and expected_condition in split_attr
# If found, return a partial function with locator and expected_condition
# For example:
# wait_visibility_of_element_located_by_id(locator_value) is equivalent to
# self.wait_for_visibility_of_element_located_by_id(locator_value) is equivalent to
# WebDriverWait(self.webdriver, 3).until(EC.visibility_of_element_located((By.ID, locator_value))
locator = None
expected_condition = None
Expand Down

0 comments on commit 200e2dd

Please sign in to comment.