Skip to content

[Bug]: Some issues with clips #501

@hgdagon

Description

@hgdagon

What actually happened?

A few minor issues I noticed I noticed with clips.
The video_id property is always an empty string.
clip.fetch_video() complains that the id cannot be empty.
I tried modifying the method to pass my own id, and I got a different error:
{'error': 'Bad Request', 'status': 400, 'message': 'The parameter "id" was malformed: value must be a numeric'}' Judging by the documentation, this would be the id of VOD this clip is sourced from, that means a clip doesn't expose the direct URL of the actual video of the clip itself. Slightly off topic, but still: clip.thumbnail.urlandclip.thumbnail.base_url` both return the same URL with the preview.

I tried quite a few clips and got these issues consistently.

What did you expect to happen instead?

Properly populated video_id property.
A property (or method) returning the direct link to the mp4 of the clip.
clip.thumbnail.base_url containing the base URL.

Minimum reproducible example:

clips = await ctx.chatter.fetch_clips()
if clips:
    clip = random.choice(clips)
    assert clip.thumbnail.url == clip.thumbnail.base_url
    print(f'{clip.video_id=}') # Empty string
    video = await clip.fetch_video() # Error

Steps to reproduce the problem

Compare url and base_url of a clip's thumbnail
try running fetch_video() on the clip.

Additional logs:

No response

System and Environment information

3.0.1

Metadata

Metadata

Assignees

Labels

Confirmed BugBug has been confirmedDocumentationDocumentation related changes.

Type

No type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions