Petpy

Latest version: v2.4.21

Safety actively analyzes 681866 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 6

2.4.21

* Now correctly returns the response from the API when only requesting one animal ID.

2.4.2

* Another hotfix for correctly incrementing re-tries in the event of a 500 error.

2.4.1

* Hotfix to correct issue with change released in 2.4.0 that would return a sparse JSON result
if an animal ID couldn't be found.
* There seems to be some intermittent issues with the Petfinder API (at the time of this writing November 7th, 2024)
where an increased volume of `500` errors are being raised, at least according to my own testing. A
change has been made to attempt an API call three times in the event of a `500` error rather than immediately
raising a `500` status code. If a non-authentication request reaches the three count retry, a sparse JSON dictionary
is returned with the response code.
- If anyone else has experienced this, please let me know.

2.4.0

* Implemented rate-limiting for API calls that could potentially exceed the quotas
set by Petfinder (50 calls/second, 1,000/day). An exponential backoff strategy is employed when rates exceed
the given limits and tries ten more times before giving up and returning the collected results.
* Access token that is generated on first initialization of Petfinder should now refresh automatically
after expiring.
* Removed the `max_page_warning` that would be displayed when there were fewer total pages
in the Petfinder API results to those requested in the `pages` parameter.
* A `response` key has been added to the returned animal or organization object. If an ID isn't found,
the `response` value will be 404.
* Type annotations have been added to the `Petfinder` methods.

2.3.0

* Added several additional search filters to the `animals()` function.
- `declawed`: Filters results by animals that are marked as declawed.
- `house_trained`: Filters results by animals that are house trained.
- `special_needs`: Filters results by animals that have special needs
* Search filters that can take multiple values in the `animals()` function,
including `age`, `gender`, `status`, `animal_type`, `size`, and `coat`, should
now correctly accept both comma-delimited strings, such as `age='baby,young'`
and lists or tuples.
* The required version for `pandas` has been updated to at least version `1.0.0`

2.2.1

Very small maintenance patch to update several `setup.py` settings. There is no need to update to this version.

Page 1 of 6

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.