title: Get a RemoteDisconnected("Remote end closed connection without" after webdriver click
body: <p>I have this simple python selenium code. After "driver.find_element_by_id('btnIniciar').click()" every coding using webdriver return a raise RemoteDisconnected("Remote end closed connection without".
   In this example, I am just trying to take a print screen of the brownser.  </p>
  
  <p>Even webdriver.close() after click() line is not working (same error message). IF I take away the click() line off, everything wents fine. So, I conclude the problem is in the click(). </p>
  
  <p>I know that when clicking on "Iniciar Teste" button it will run a javascript to evaluate internet speed. 
  Any ideas ?</p>
  
  <pre><code>from selenium import webdriver
  import time
  from datetime import datetime
  
  driver = webdriver.Firefox()
  driver.get('http://www.brasilbandalarga.com.br/bbl/')
  driver.find_element_by_id('btnIniciar').click()
  time.sleep(60)
  figura = datetime.now().strftime("%Y%m%d_%H%M%S.png")
  print(figura)
  driver.get_screenshot_as_file('/tmp/'+figura)
  </code></pre>
  
  <p>The complete error message:</p>
  
  <pre><code>$ python3 ./bandalarga.py 
  20180620_122229.png
  Traceback (most recent call last):
    File "./bandalarga.py", line 22, in &lt;module&gt;
      driver.get_screenshot_as_file('/home/santana/NET/'+figura)
    File "/usr/local/lib/python3.5/dist-packages/selenium/webdriver/remote/webdriver.py", line 1010, in get_screenshot_as_file
      png = self.get_screenshot_as_png()
    File "/usr/local/lib/python3.5/dist-packages/selenium/webdriver/remote/webdriver.py", line 1042, in get_screenshot_as_png
      return base64.b64decode(self.get_screenshot_as_base64().encode('ascii'))
    File "/usr/local/lib/python3.5/dist-packages/selenium/webdriver/remote/webdriver.py", line 1052, in get_screenshot_as_base64
      return self.execute(Command.SCREENSHOT)['value']
    File "/usr/local/lib/python3.5/dist-packages/selenium/webdriver/remote/webdriver.py", line 312, in execute
      response = self.command_executor.execute(driver_command, params)
    File "/usr/local/lib/python3.5/dist-packages/selenium/webdriver/remote/remote_connection.py", line 472, in execute
      return self._request(command_info[0], url, body=data)
    File "/usr/local/lib/python3.5/dist-packages/selenium/webdriver/remote/remote_connection.py", line 496, in _request
      resp = self._conn.getresponse()
    File "/usr/lib/python3.5/http/client.py", line 1197, in getresponse
      response.begin()
    File "/usr/lib/python3.5/http/client.py", line 297, in begin
      version, status, reason = self._read_status()
    File "/usr/lib/python3.5/http/client.py", line 266, in _read_status
      raise RemoteDisconnected("Remote end closed connection without"
  http.client.RemoteDisconnected: Remote end closed connection without response
  </code></pre>