title: Selenium navigate without getting logged out
body: <p>What I want to do is follow one Instagram account in Chrome, incognito mode. The problem is that after I log in successfully, the driver gets the account's link(when the follow function is called) and I am no longer logged in.</p>
  
  <p>I did the same operations without the automated driver and there is no problem. </p>
  
  <p>Here are my 2 functions:</p>
  
  <pre><code>def login(driver):
      # Auto log in to instagram
      driver.get('https://www.instagram.com/accounts/login/')
      # Wait until the screen has loaded
      try:
          element = WebDriverWait(driver, 15).until(
              EC.presence_of_all_elements_located((By.CLASS_NAME, "_ph6vk"))
              )
      except Exception:
          print("Accounts page timed out")
      input_elem = driver.find_elements_by_class_name("_ph6vk")
  
      input_elem[0].send_keys("username")
      input_elem[1].send_keys("password")
      login_button = driver.find_element_by_class_name("_qv64e")
      login_button.click()
  
  def follow(driver, account_to_follow_link):
  
      driver.get(account_to_follow_link)
  
      #driver.close()
  </code></pre>
  
  <p>And here is my driver instantiation and its options:</p>
  
  <pre><code>chrome_options = Options()
  chrome_options.add_argument("--incognito")
  #chrome_options.add_argument("--headless")
  #chrome_options.add_argument("--window-size=1920x1080")
  
  
  # Path of current driver &amp; instantiation of driver object
  os.chdir(r'C:\ig_automation')
  driver = os.getcwd() +"\\chromedriver.exe"
  driver = webdriver.Chrome(chrome_options=chrome_options, 
  executable_path=driver)
  </code></pre>