From 1c6aed1d5cc971949c3f4ac74254efdf777ee47d Mon Sep 17 00:00:00 2001 From: David Teather <34144122+davidteather@users.noreply.github.com> Date: Fri, 9 Feb 2024 09:41:41 -0600 Subject: [PATCH] V6.2.1 (#1113) * remove sponsors * Fix count parameter for hashtag, user, and trending classes (#1108) * Fix trending count (#1103) Co-authored-by: ben.wisnet * Made author field optional (#1099) Fixed issue where error is raised for some videos that are missing the "author" field * bump version --------- Co-authored-by: lysmm203 <65572921+lysmm203@users.noreply.github.com> Co-authored-by: Ben3056 <32847329+Ben3056@users.noreply.github.com> Co-authored-by: ben.wisnet Co-authored-by: Tristan Lee --- .sphinx/conf.py | 2 +- CITATION.cff | 4 ++-- README.md | 8 -------- TikTokApi/api/hashtag.py | 2 +- TikTokApi/api/trending.py | 2 +- TikTokApi/api/user.py | 2 +- TikTokApi/api/video.py | 2 +- setup.py | 2 +- 8 files changed, 8 insertions(+), 16 deletions(-) diff --git a/.sphinx/conf.py b/.sphinx/conf.py index c9fb69ae..413f6fac 100644 --- a/.sphinx/conf.py +++ b/.sphinx/conf.py @@ -16,7 +16,7 @@ project = "TikTokAPI" copyright = "2023, David Teather" author = "David Teather" -release = "v6.2.0" +release = "v6.2.1" # -- General configuration --------------------------------------------------- # https://www.sphinx-doc.org/en/main/usage/configuration.html#general-configuration diff --git a/CITATION.cff b/CITATION.cff index 65b95b3e..c23b330c 100644 --- a/CITATION.cff +++ b/CITATION.cff @@ -5,5 +5,5 @@ authors: orcid: "https://orcid.org/0000-0002-9467-4676" title: "TikTokAPI" url: "https://github.com/davidteather/tiktok-api" -version: 6.2.0 -date-released: 2023-11-27 +version: 6.2.1 +date-released: 2024-02-09 diff --git a/README.md b/README.md index 3fccab7c..6f83beca 100644 --- a/README.md +++ b/README.md @@ -17,14 +17,6 @@ These sponsors have paid to be placed here and beyond that I do not have any aff TikAPI is a paid TikTok API service providing a full out-of-the-box solution, making life easier for developers — trusted by 500+ companies. -
- - Ensemble Data - -
- Ensemble Data is the leading API provider for scraping all the major Social Media.
We provide 100+ Million posts / day to the largest Marketing and Social listening platforms. -
-
## Table of Contents diff --git a/TikTokApi/api/hashtag.py b/TikTokApi/api/hashtag.py index af81cca3..4bbe5709 100644 --- a/TikTokApi/api/hashtag.py +++ b/TikTokApi/api/hashtag.py @@ -111,7 +111,7 @@ async def videos(self, count=30, cursor=0, **kwargs) -> Iterator[Video]: while found < count: params = { "challengeID": self.id, - "count": 30, + "count": count, "cursor": cursor, } diff --git a/TikTokApi/api/trending.py b/TikTokApi/api/trending.py index 429cf592..a164432c 100644 --- a/TikTokApi/api/trending.py +++ b/TikTokApi/api/trending.py @@ -37,7 +37,7 @@ async def videos(count=30, **kwargs) -> Iterator[Video]: while found < count: params = { "from_page": "fyp", - "count": 30, + "count": count, } resp = await Trending.parent.make_request( diff --git a/TikTokApi/api/user.py b/TikTokApi/api/user.py index 7c36388a..7c92edd9 100644 --- a/TikTokApi/api/user.py +++ b/TikTokApi/api/user.py @@ -115,7 +115,7 @@ async def videos(self, count=30, cursor=0, **kwargs) -> Iterator[Video]: while found < count: params = { "secUid": self.sec_uid, - "count": 35, + "count": count, "cursor": cursor, } diff --git a/TikTokApi/api/video.py b/TikTokApi/api/video.py index 9cb1f9c8..552e26c8 100644 --- a/TikTokApi/api/video.py +++ b/TikTokApi/api/video.py @@ -218,7 +218,7 @@ def __extract_from_data(self) -> None: self.create_time = datetime.fromtimestamp(timestamp) self.stats = data["stats"] - author = data["author"] + author = data.get("author") if isinstance(author, str): self.author = self.parent.user(username=author) else: diff --git a/setup.py b/setup.py index 7156eefe..e1722139 100644 --- a/setup.py +++ b/setup.py @@ -8,7 +8,7 @@ setuptools.setup( name="TikTokApi", packages=setuptools.find_packages(), - version="6.2.0", + version="6.2.1", license="MIT", description="The Unofficial TikTok API Wrapper in Python 3.", author="David Teather",