Exceptions

class splinter.exceptions.DriverNotFoundError[source]

Exception raised when a driver is not found.

Example

>>> from splinter import Browser
>>> b = Browser('unknown driver') # raises DriverNotFoundError
class splinter.exceptions.ElementDoesNotExist[source]

Exception raised when an element is not found in the page.

The exception is raised only when someone tries to access the element, not when the driver is finding it.

Example

>>> elements = browser.find_by_id('unknown-id') # returns an empty list
>>> elements[0] # raises ElementDoesNotExist