woob.exceptions
¶
- exception BrowserUserBanned(message='', bad_fields=None)[source]¶
Bases:
BrowserIncorrectPassword
Bases:
Exception
- exception ScrapingBlocked[source]¶
Bases:
BrowserUnavailable
- exception BrowserQuestion(*fields)[source]¶
Bases:
BrowserInteraction
When raised by a browser,
- exception OTPQuestion(*fields)[source]¶
Bases:
BrowserQuestion
- class OTPSentType[source]¶
Bases:
object
- UNKNOWN = 'unknown'¶
- SMS = 'sms'¶
- MOBILE_APP = 'mobile_app'¶
- EMAIL = 'email'¶
- DEVICE = 'device'¶
- exception SentOTPQuestion(field_name, medium_type='unknown', medium_label=None, message='', expires_at=None)[source]¶
Bases:
OTPQuestion
Question when the OTP was sent by the site to the user (e.g. SMS)
- exception OfflineOTPQuestion(field_name, input=None, medium_label=None, message='', expires_at=None)[source]¶
Bases:
OTPQuestion
Question when the user has to compute the OTP themself (e.g. card reader)
- class DecoupledMedium[source]¶
Bases:
object
- UNKNOWN = 'unknown'¶
- SMS = 'sms'¶
- MOBILE_APP = 'mobile_app'¶
- EMAIL = 'email'¶
- exception DecoupledValidation(message='', resource=None, medium_type='unknown', medium_label=None, expires_at=None, *values)[source]¶
Bases:
BrowserInteraction
- exception AppValidation(*args, **kwargs)[source]¶
Bases:
DecoupledValidation
- exception AppValidationCancelled(message='')[source]¶
Bases:
AppValidationError
- exception AppValidationExpired(message='')[source]¶
Bases:
AppValidationError
- exception BrowserRedirect(url, resource=None)[source]¶
Bases:
BrowserInteraction
- exception CaptchaQuestion(type=None, **kwargs)[source]¶
Bases:
Exception
Site requires solving a CAPTCHA (base class)
- exception WrongCaptchaResponse(message=None)[source]¶
Bases:
Exception
when website tell us captcha response is not good
- exception ImageCaptchaQuestion(image_data)[source]¶
Bases:
CaptchaQuestion
- type = 'image_captcha'¶
- image_data = None¶
- exception RecaptchaV2Question(website_key, website_url)[source]¶
Bases:
CaptchaQuestion
- type = 'g_recaptcha'¶
- website_key = None¶
- website_url = None¶
- exception RecaptchaQuestion(website_key, website_url)[source]¶
Bases:
CaptchaQuestion
- type = 'g_recaptcha'¶
- website_key = None¶
- website_url = None¶
- exception GeetestV4Question(website_url, gt)[source]¶
Bases:
CaptchaQuestion
- type = 'GeeTestTaskProxyless'¶
- website_url = None¶
- gt = None¶
- exception RecaptchaV3Question(website_key, website_url, action=None, min_score=None, is_enterprise=False)[source]¶
Bases:
CaptchaQuestion
- type = 'g_recaptcha'¶
- website_key = None¶
- website_url = None¶
- action = None¶
- min_score = None¶
- is_enterprise = False¶
- exception FuncaptchaQuestion(website_key, website_url, sub_domain=None, data=None)[source]¶
Bases:
CaptchaQuestion
- type = 'funcaptcha'¶
- website_key = None¶
- website_url = None¶
- sub_domain = None¶
- data = None¶
Optional additional data, as a dictionary.
For example, a site could transmit a ‘blob’ property which you should get, and transmit as {‘blob’: your_blob_value} through this property.
- exception HcaptchaQuestion(website_key, website_url)[source]¶
Bases:
CaptchaQuestion
- type = 'hcaptcha'¶
- website_key = None¶
- website_url = None¶
- exception BrowserSSLError[source]¶
Bases:
BrowserUnavailable
- exception FormFieldConversionWarning[source]¶
Bases:
UserWarning
A value has been set to a form’s field and has been implicitly converted.
- class ActionType[source]¶
Bases:
object
- ACKNOWLEDGE = 1¶
Must acknowledge new Terms of Service or some important message
- FILL_KYC = 2¶
User information must be filled on website
- ENABLE_MFA = 3¶
MFA must be enabled on website
- PERFORM_MFA = 4¶
Must perform MFA on website directly to unlock scraping
It is different from DecoupledValidation.
- PAYMENT = 5¶
Must pay site for the feature or pay again for the subscription which has ended
- CONTACT = 6¶
Must contact site support or a customer relation person for another problem
The problem should ideally be described in ActionNeeded.message.
- exception ActionNeeded(message=None, *, locale=None, action_type=None, url=None, page=None)[source]¶
Bases:
Exception
- exception AuthMethodNotImplemented(message=None, *, locale=None, action_type=None, url=None, page=None)[source]¶
Bases:
ActionNeeded
- exception BrowserPasswordExpired(message=None, *, locale=None, action_type=None, url=None, page=None)[source]¶
Bases:
ActionNeeded
- exception NeedInteractiveForRedirect[source]¶
Bases:
NeedInteractive
An authentication is required to connect and credentials are not supplied
- exception NeedInteractiveFor2FA[source]¶
Bases:
NeedInteractive
A 2FA is required to connect, credentials are supplied but not the second factor