Skip to content

Commit

Permalink
chore: Fix linter error on AudioCodec (shaka-project#188)
Browse files Browse the repository at this point in the history
Introduced in shaka-project#185

Co-authored-by: Álvaro Velad Galván <[email protected]>
  • Loading branch information
joeyparrish and avelad authored Nov 6, 2024
1 parent 5206424 commit d9a3d38
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions streamer/packager_node.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,12 @@
from . import node_base
from . import pipeline_configuration

from streamer.bitrate_configuration import AudioCodec
from streamer.input_configuration import MediaType
from streamer.output_stream import OutputStream
from streamer.pipeline_configuration import EncryptionMode, PipelineConfig
from streamer.util import is_url
from typing import List, Optional, Union
from typing import List, Optional, Union, cast

# Alias a few classes to avoid repeating namespaces later.
ManifestFormat = pipeline_configuration.ManifestFormat
Expand Down Expand Up @@ -136,7 +137,7 @@ def _setup_stream(self, stream: OutputStream) -> str:
dict['skip_encryption'] = str(stream.input.skip_encryption)

if stream.type == MediaType.AUDIO:
dict['hls_group_id'] = str(stream.codec.value)
dict['hls_group_id'] = str(cast(AudioCodec, stream.codec).value)

if stream.input.drm_label:
dict['drm_label'] = stream.input.drm_label
Expand Down

0 comments on commit d9a3d38

Please sign in to comment.