Closed MunifTanjim closed 6 days ago
The changes in the pull request focus on the StremThru
class within the streaming_providers/stremthru/client.py
file. Key modifications include the removal of the _validate_error_response
method, with its functionality incorporated into the _make_request
method, which now raises a ProviderException
with enhanced error messages. Additionally, several methods have been updated to return more comprehensive data, including the entire response instead of just specific fields, streamlining error handling and improving data accessibility.
File Path | Change Summary |
---|---|
streaming_providers/stremthru/client.py | - Removed _validate_error_response method; integrated into _make_request method. - Updated _make_request to raise ProviderException with detailed error messages. - Modified add_magnet_link to return entire response_data . - Updated get_torrent_info to return complete response instead of just "data". - Simplified get_available_torrent by removing validation call and accessing "items" directly. |
In the fields where data flows,
A rabbit hops where clarity grows.
With messages bright and errors tamed,
Our StremThru's now more easily named.
So letβs dance in the code so fine,
For every change, a reason to shine! πβ¨
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
StremThru response are in shape of either
{ data: { ... } }
or{ error: { ... } }
.._make_request
method is already returning.data
and raising error otherwise. So no need to access["data"]
again on the return value of._make_request
method.Summary by CodeRabbit
New Features
Bug Fixes