Skip to content

Fix typos and example code mistakes #48

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 7, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -218,28 +218,28 @@ solver.report(id, False) # captcha solved incorrectly
```

### Error handling
If case of an error captcha solver throws an exception. It's important to properly handle these cases. We recommend to use `try except` to handle exceptions.
In case of an error, the captcha solver throws an exception. It's important to properly handle these cases. We recommend using `try except` to handle exceptions.
```python
Try:
try:
result = solver.text('If tomorrow is Saturday, what day is today?')
Except ValidationException as e:
except ValidationException as e:
# invalid parameters passed
print(e)
Except NetworkException as e:
except NetworkException as e:
# network error occurred
print(e)
Except ApiException as e:
except ApiException as e:
# api respond with error
print(e)
Except TimeoutException as e:
except TimeoutException as e:
# captcha is not solved so far
print(e)
```


### Proxies

You can pass your proxy as an additional argumen for methods: recaptcha, funcaptcha and geetest. The proxy will be forwarded to the API to solve the captcha.
You can pass your proxy as an additional argument for methods: recaptcha, funcaptcha and geetest. The proxy will be forwarded to the API to solve the captcha.

```python
proxy={
Expand Down