You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[BREAKING] Removed the Client.searchfeature argument. Instead, use the boolean use_hubtraffic to specify if you want to use a JSONQuery or an HTMLQuery
[BREAKING] Removed Client.search_pornstar. It is much easier to search for a user and you can use more filters
[BREAKING] Removed Query slices implementations
Reduced number of query objects to 5 elementary queries (JSONQuery, VideoQuery, UserQuery and FeedQuery)
Added Query.sample as a way to replace query slices. You can use it to filter query items and set a max limit. More controls are to be expected in the futre
Refactored the built-in CLI script. More functionnalities are to be expected in the future
Each query now fetch their videos according to a container. By default, the global pornhub container (consts.re.container). It can be overrided by Query.container_hint to adapt to different pages. The hint should be a consts.WrappedRegex or a special callable.
The feed object can now be iterated through like a query. Iterate client.account.feed instead of client.account.feed.feed
Feed items now have a proper representation
Added video interaction methods: video.like(), video.favorite(), video.watch_later()
Added video properties: video.liked, video.is_favorite, video.watched, video.id, video.is_free_premium, video.preview [BETA]
Added EmptyQuery, representing an empty query. Used to silence low priority query errors, e.g. when a pornstar does not have uploads.
Added a slient option to client.call to not log some repetitive calls (e.g. video segment calls who are already displayed by the download backend anyway)
Added video._supports_queries and the _QuerySupportIndex dataclass. Used internally by Video objects to keep trace of which queries are available for a video.
Client and Video objects now keep trace of their tokens for API calls
Video fetching regex is now split between consts.re.get_videos and consts.re.eval_video for optimization purposes
Added markers and preview parsing to video fetching regexes
User objects representation now displays the user type too
User objects now "smartly" select a query url and container hint for user videos and user uploads queries (#27)
Added utils.head which silently makes HEAD requests to check URLs
Implemented video._as_query. This property emulates what would the initial video data be like if it was fetched by a query. This allows access to more data (watched status, video preview, etc.) but is implemented in the least optimized way (with a temporary pornhub playlist)