splinter icon indicating copy to clipboard operation
splinter copied to clipboard

UnboundLocalError when running splinter browser

Open EAly opened this issue 6 years ago • 4 comments

I get this error:

UnboundLocalError: local variable 'e' referenced before assignment

When I try to use splinter browser as:

gekoExe_path = {'executable_path': <gekodriver path>}
browser= Browser('firefox', **gekoExe_path, headless= False)

I'm using splinter version: '0.13.0' and firefox

EAly avatar Feb 24 '20 05:02 EAly

The Browser object has bug. I see it fixed in the source code but not in the pip packages.

mikiboy avatar Feb 24 '20 23:02 mikiboy

I solved that by installing the splinter from source code as mentioned here and adding the gekodriver executable to path.

EAly avatar Feb 25 '20 00:02 EAly

The Browser object has bug. I see it fixed in the source code but not in the pip packages.

Are there any plans to create a new release? This bug is very frustrating as it prevents you from seeing the actual underlying exception.

mdilovar avatar Mar 30 '20 18:03 mdilovar

Either you can use the source code directly in your project. Or don't use the Browser object but directly call the required driver.

mikiboy avatar Mar 31 '20 11:03 mikiboy