upsies.utils.predbs.common

Classes and functions that are not specific to PredbApiBase subclasses

Functions

upsies.utils.predbs.common.assert_not_abbreviated_filename(filepath)[source]

Raise SceneError if filepath points to an abbreviated scene file name like abd-mother.mkv

upsies.utils.predbs.common.get_needed_keys(release_info, exclude=())[source]

Return needed ReleaseInfo keys to identify release

Parameters:
  • release_infoReleaseInfo instance or any dict-like object with the keys type and source

  • exclude – Sequence of keys to exclude from the returned sequence

Returns:

Sequence of required keys or empty sequence if release_info doesn’t contain a type

upsies.utils.predbs.common.get_season_pack_name(release_name)[source]

Remove episode information (e.g. “E03”) from release_name

upsies.utils.predbs.common.is_abbreviated_filename(filepath)[source]

Return whether filepath points to an abbreviated scene file name like abd-mother.mkv

upsies.utils.predbs.common.is_mixed_season_pack(directory)[source]

Return whether directory is a season pack with episodes from different groups