title: MaxRetryError Selenium
body: <p>I tried writing a simple script that checks the website every hour and sends me an email when it finds there's availability.</p>
  <p>I figured doing this evey hour shouldn't trigger any problems but I'm getting the following error:</p>
  <pre><code>MaxRetryError: HTTPConnectionPool(host='127.0.0.1', port=60745): Max retries exceeded with url: /session/900f45d6c8c800f2a8ebcf43daa05b69/url (Caused by NewConnectionError('&lt;urllib3.connection.HTTPConnection object at 0x7fa42c261c10&gt;: Failed to establish a new connection: [Errno 61] Connection refused'))
  </code></pre>
  <p>This is my code:</p>
  <pre><code>import schedule
  import time
  from selenium import webdriver
  from selenium.webdriver.chrome.options import Options
  from notification import *
  #script i have to send an email (works fine)
  
  PATH = &quot;mypath&quot;
  # i have the path where there drivers are
  
  chrome_options = Options()
  chrome_options.add_argument(&quot;--headless&quot;)
  chrome_options.add_argument(&quot;--window-size=1920x1080&quot;)
  # to not open the browser
  
  driver = webdriver.Chrome(options=chrome_options, executable_path=PATH)
  
  def get_stock():
      driver.get(&quot;website i'm trying to check&quot;)
      # access the website
      search = driver.find_element_by_name(&quot;add&quot;)
      # add is the name of the button i wanna check
      result = search.is_enabled()
      print(result)
      driver.quit()
  
  
  schedule.every().hour.do(get_stock)
  # run the get_stock function every hour
  
  c = 0
  # initialize the loop
  
  while c == 0:
      schedule.run_pending()
      c = get_stock()
      # set the seed equal to the get_stock so that it stops once it becomes True
      time.sleep(1)
      print(get_stock())
  
  
  email(&quot;Now there's a stock.&quot;)
  #using my notification script to send the email
  </code></pre>
  <p>I'm a beginner so any help will be appreciated.</p>