wi1-bot 2.0.0__py3-none-any.whl → 2.0.1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
wi1_bot/config.py CHANGED
@@ -48,12 +48,13 @@ class DiscordConfig(TypedDict):
48
48
 
49
49
 
50
50
  class TranscodingProfile(TypedDict):
51
- copy_all_streams: bool
52
51
  video_codec: NotRequired[str]
53
52
  video_bitrate: NotRequired[int]
54
53
  audio_codec: NotRequired[str]
55
54
  audio_channels: NotRequired[int]
56
55
  audio_bitrate: NotRequired[str]
56
+ copy_all_streams: NotRequired[bool]
57
+ languages: NotRequired[str]
57
58
 
58
59
 
59
60
  class TranscodingConfig(TypedDict):
wi1_bot/webhook.py CHANGED
@@ -66,20 +66,13 @@ def on_download(req: dict[str, Any]) -> None:
66
66
 
67
67
  quality_options = config["transcoding"]["profiles"][quality_profile]
68
68
 
69
- # python 3.11: TranscodingProfile and typing.LiteralString
70
- def get_key(d: Any, k: str) -> Any:
71
- try:
72
- return d[k]
73
- except KeyError:
74
- return None
75
-
76
- copy_all_streams = get_key(quality_options, "copy_all_streams")
77
- languages = get_key(quality_options, "languages")
78
- video_codec = get_key(quality_options, "video_codec")
79
- video_bitrate = get_key(quality_options, "video_bitrate")
80
- audio_codec = get_key(quality_options, "audio_codec")
81
- audio_channels = get_key(quality_options, "audio_channels")
82
- audio_bitrate = get_key(quality_options, "audio_bitrate")
69
+ copy_all_streams = quality_options.get("copy_all_streams", None)
70
+ languages = quality_options.get("languages", None)
71
+ video_codec = quality_options.get("video_codec", None)
72
+ video_bitrate = quality_options.get("video_bitrate", None)
73
+ audio_codec = quality_options.get("audio_codec", None)
74
+ audio_channels = quality_options.get("audio_channels", None)
75
+ audio_bitrate = quality_options.get("audio_bitrate", None)
83
76
 
84
77
  transcoder.queue.add(
85
78
  path=str(path),
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: wi1-bot
3
- Version: 2.0.0
3
+ Version: 2.0.1
4
4
  Summary: Discord bot for Radarr/Sonarr integration
5
5
  Project-URL: Homepage, https://github.com/wthueb/wi1-bot
6
6
  Author-email: William Huebner <wilhueb@gmail.com>
@@ -1,7 +1,7 @@
1
1
  wi1_bot/__init__.py,sha256=dYlvBffClqwInBRSxSAoJHuujuh4yuPderFR4n7Odko,161
2
- wi1_bot/config.py,sha256=2gN9Hx2-nl2L4n3tLlW-XmmKMxL6jOSGMD4Re9um0jI,2181
2
+ wi1_bot/config.py,sha256=ndL3BxiOpXiDQGYNEIPtuusekS25miPFQrEphINxnsQ,2226
3
3
  wi1_bot/push.py,sha256=6EwQ1eXcJnQimAi0dOm1_t7Am056zob-1-EOkytGZWg,783
4
- wi1_bot/webhook.py,sha256=11rzmxhXnDeXWlgEnOLh26WP79rLeG71HaDvKUXuUcA,3665
4
+ wi1_bot/webhook.py,sha256=xTN_-Ivdt1ANJFWkhF4W8csyqwfBNH33d-eWbsWOPS4,3482
5
5
  wi1_bot/arr/__init__.py,sha256=-6UE81yY6OhD6-nbLindChE_HlwsNRuL8JijUmo_Q6k,149
6
6
  wi1_bot/arr/download.py,sha256=02AYFglnFdWSG8xj_TaJc6l2wjybyhUW6F97CnoyUFw,1381
7
7
  wi1_bot/arr/episode.py,sha256=0K_auUYwkBBd_Ludc4-4z7lSW8HRQ3mchFQ7FR10JSU,1041
@@ -23,8 +23,8 @@ wi1_bot/scripts/transcode_item.py,sha256=21MeeIZ9wIRhAY-FOEgOdPsg6YOLlSUj59r8NkT
23
23
  wi1_bot/transcoder/__init__.py,sha256=B4xr82UtIFc3tyy_MEZdZKMukYW0yejPnfsGowaTIM0,105
24
24
  wi1_bot/transcoder/transcode_queue.py,sha256=W7r2I7OD8QuxseCEb7_ddOvYXiBBLmKLvCs2IgJJ92I,1856
25
25
  wi1_bot/transcoder/transcoder.py,sha256=2wIgDPkrrXcrSjA1HpYGd0RX5wonw1zfltJqGzCaorM,9163
26
- wi1_bot-2.0.0.dist-info/METADATA,sha256=Bwt1ZBD6ZLxmbMt3rn5sU2yl-JMMxYlxYCAfeGnO4bY,3663
27
- wi1_bot-2.0.0.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
28
- wi1_bot-2.0.0.dist-info/entry_points.txt,sha256=pF5EawAQsUNMHs5exynpNdRq9g4dODg-RaPkx2MyYLU,184
29
- wi1_bot-2.0.0.dist-info/licenses/LICENSE,sha256=6V4_mQoPoLJl77_WMsQRQMDG2mnIhDUdfCmMkqM9Qwc,1072
30
- wi1_bot-2.0.0.dist-info/RECORD,,
26
+ wi1_bot-2.0.1.dist-info/METADATA,sha256=bfPmddao9hTXv6WmyqiJP4kN06dFLAA8TMnle7LDWo8,3663
27
+ wi1_bot-2.0.1.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
28
+ wi1_bot-2.0.1.dist-info/entry_points.txt,sha256=pF5EawAQsUNMHs5exynpNdRq9g4dODg-RaPkx2MyYLU,184
29
+ wi1_bot-2.0.1.dist-info/licenses/LICENSE,sha256=6V4_mQoPoLJl77_WMsQRQMDG2mnIhDUdfCmMkqM9Qwc,1072
30
+ wi1_bot-2.0.1.dist-info/RECORD,,