Skip to content

download_audio: delegate the policy to yb.download.download_audio_bounded #122

Closed

Description

@thorwhalen

yb now ships the link-to-audio policy as one function (reeleehq/yb#44, PR reeleehq/yb#48, yb >= 0.1.24 once released): target check, playlist/live/duration refusal, pinned caps, mp3, copyright notice, per-call result directory.

Make download_audio a thin caller: keep creds.check() and as_tool_error; pass creds.opts as extra_opts (restricted to yb.download.DEPLOYMENT_OPT_KEYS, else ValueError), _docs._validate_target as validate_target, the env-tunable caps as max_bytes/max_duration_s; ingest result.path then remove result.path.parent; carry result.notice. Bump the yb[download] floor. reelee and muvid can then add thin ingest tools the same way (see reeleehq/reelee#280).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions