Added typing and redid function comment
This commit is contained in:
2 files changed
+8
-6
No files matched your search
@@ -15,12 +15,14 @@ console = Console()
|
||||
storymode = False
|
||||
|
||||
|
||||
def download_screenshots_of_reddit_posts(reddit_object, screenshot_num):
|
||||
"""Downloads screenshots of reddit posts as they are seen on the web.
|
||||
def download_screenshots_of_reddit_posts(reddit_object:dict[str], screenshot_num:int):
|
||||
"""Downloads screenshots of reddit posts as seen on the web. Downloads to assets/temp/png
|
||||
|
||||
Args:
|
||||
reddit_object: The Reddit Object you received in askreddit.py
|
||||
screenshot_num: The number of screenshots you want to download.
|
||||
"""
|
||||
reddit_object (dict[str]): Reddit object received from subreddit.py
|
||||
screenshot_num (int): Number of screenshots to downlaod
|
||||
"""
|
||||
|
||||
print_step("Downloading screenshots of reddit posts...")
|
||||
|
||||
# ! Make sure the reddit screenshots folder exists
|
||||
|
||||
@@ -23,7 +23,7 @@ def save_text_to_mp3(reddit_obj):
|
||||
"""Saves text to MP3 files. Goes through the reddit_obj and generates the title MP3 file and a certain number of comments until the total amount of time exceeds VIDEO_LENGTH seconds.
|
||||
|
||||
Args:
|
||||
reddit_obj (dict[str]): Reddit object received from reddit API in askreddit.py
|
||||
reddit_obj (dict[str]): Reddit object received from reddit API in subreddit.py
|
||||
|
||||
Returns:
|
||||
tuple[int,int]: (total length of the audio, the number of comments audio was generated for)
|
||||
|
||||
Reference in new issue
Block a user