Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tools: added title/desc checks to split.py #63

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

destevae
Copy link
Collaborator

@destevae destevae commented Jul 4, 2024

#61 Added the title and description length/character checks to split.py so it sends a warning message when the script is run.

I looked into adding the checks when we get the JSON, but couldn't find a good way since we use a curl command to do so. I've kept the title/desc checks in upload.py, but let me know if we should delete them there and only have them in split.py.

@destevae destevae linked an issue Jul 4, 2024 that may be closed by this pull request
@destevae destevae requested a review from EaterOA July 4, 2024 20:23
@@ -134,6 +157,11 @@ def main():
talk_path = os.path.join(subdir_path, talk_name)
thumbnail_path = os.path.join(subdir_path, image_name)

youtube_desc = make_video_description(talk, talk["description"])
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think these should be done further up all at once prior to downloading / cutting any video. With potentially long-processing scripts, as much validation should be done upfront as possible, instead of potentially having the user come back from dinner to see that it threw an exception after processing one video.

I'm not sure if it'll be used, but this also makes it cleaner to offer a cmdline arg to not do this validation, say if the user really doesn't care about fixing descriptions right now. Letting the validation in upload.py stay is fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

More automated way of dealing with too-long titles
2 participants