title: Using selenium chromedriver and python with chromium on Linux
body: <p>I'm running Arch Linux with current chromium browser version (80.0.3987.100-1) and all packages fully updated.</p>
  
  <p>I have a python script that requires <a href="https://chromedriver.chromium.org/downloads" rel="nofollow noreferrer">chromedriver</a>. The <a href="https://chromedriver.chromium.org/getting-started" rel="nofollow noreferrer">instructions</a> there say, </p>
  
  <ul>
  <li>ChromeDriver is a separate executable </li>
  <li>Help WebDriver find the downloaded ChromeDriver executable by specifying the path</li>
  <li>[python] driver = webdriver.Chrome('/path/to/chromedriver')</li>
  </ul>
  
  <p>In <a href="https://www.archlinux.org/packages/extra/x86_64/chromium/" rel="nofollow noreferrer">chromium</a>, chromedriver is included (at least on Arch, and probably on all distros):</p>
  
  <pre><code>/usr/lib/chromium/chromedriver
  </code></pre>
  
  <p>I have a simple question. <strong>When using chromium, is it necessary to provide a path to chromedriver</strong>, as in the example below?</p>
  
  <pre><code>driver = webdriver.Chrome(executable_path="/usr/lib/chromium/chromedriver",options=chromeOptions)
  </code></pre>
  
  <p>I see from the instructions that if the path is not provided explicitly, it will search. But I wish to avoid searching multiple paths and I want to avoid any chance of runtime errors due to chromedriver not being found. </p>
  
  <p>I would guess that because chromedriver and chromium are developed by the same team, and they are packaged together, I can avoid any problems without having to hard code the path. I will also see what works on my system, but I am looking for feedback based on actual real-world experience. I don't want to encounter an error related to this when I deploy. My question is simply can anyone confirm that this will work correctly under the conditions above without the path?</p>
  
  <p><strong>EDIT: In response to a comment:</strong> This appears to be the documentation:</p>
  
  <p><a href="https://selenium.dev/selenium/docs/api/py/webdriver_chrome/selenium.webdriver.chrome.service.html" rel="nofollow noreferrer">https://selenium.dev/selenium/docs/api/py/webdriver_chrome/selenium.webdriver.chrome.service.html</a></p>
  
  <p>However, it does not mention what types of exceptions it throws. Furthermore, adding exception handling is not relevant to my question. The documentation states that this method will search if a path is not provided. I want to know if the <strong>first location searched</strong> is <code>/usr/lib/chromium/chromedriver</code>. The documentation I found also does not address that.</p>
  
  <p>I know this is a super simple question. Maybe it is too simple? If I can find the source code, I believe I can read it and learn the answer. However, I asked in part so that I would not have to spend hours trying to figure out the answer for myself.</p>