fut icon indicating copy to clipboard operation
fut copied to clipboard

Catch errors

Open AlPitchou opened this issue 7 years ago • 1 comments
trafficstars

Hello,

I'm new to python and wondering how I can catch connection errors properly...

    try :
        session=fut.Core(my params)
    except ??? :
        do something

What are the errors available ? Those listed in expections.py ?UnknownError, FutError... ? Am I doing it correctly ?

AlPitchou avatar Nov 24 '17 14:11 AlPitchou

Yes, but You probably have to first import error objects, for example:

from fut.exceptions import FutError

oczkers avatar Nov 29 '17 16:11 oczkers