ffmpeg-normalize 1.29.0__py2.py3-none-any.whl → 1.29.2__py2.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.
@@ -26,7 +26,9 @@ def create_parser() -> argparse.ArgumentParser:
26
26
  ffmpeg-normalize v{} -- command line tool for normalizing audio files
27
27
  """.format(__version__)
28
28
  ),
29
- # usage="%(prog)s INPUT [INPUT ...] [-o OUTPUT [OUTPUT ...]] [options]",
29
+ # manually overridden because argparse generates the wrong order of arguments, see:
30
+ # https://github.com/slhck/ffmpeg-normalize/issues/132#issuecomment-662516535
31
+ usage="%(prog)s INPUT [INPUT ...] [-o OUTPUT [OUTPUT ...]] [options]",
30
32
  formatter_class=argparse.RawTextHelpFormatter,
31
33
  epilog=textwrap.dedent(
32
34
  """\
@@ -24,6 +24,8 @@ _logger = logging.getLogger(__name__)
24
24
  AUDIO_ONLY_FORMATS = {"aac", "ast", "flac", "mka", "oga", "ogg", "opus", "wav"}
25
25
  ONE_STREAM = {"aac", "ast", "flac", "mp3", "wav"}
26
26
 
27
+ TQDM_BAR_FORMAT = "{desc}: {percentage:3.2f}% |{bar}{r_bar}"
28
+
27
29
 
28
30
  def _to_ms(**kwargs: str) -> int:
29
31
  hour = int(kwargs.get("hour", 0))
@@ -189,7 +191,12 @@ class MediaFile:
189
191
 
190
192
  # run the second pass as a whole
191
193
  if self.ffmpeg_normalize.progress:
192
- with tqdm(total=100, position=1, desc="Second Pass") as pbar:
194
+ with tqdm(
195
+ total=100,
196
+ position=1,
197
+ desc="Second Pass",
198
+ bar_format=TQDM_BAR_FORMAT,
199
+ ) as pbar:
193
200
  for progress in self._second_pass():
194
201
  pbar.update(progress - pbar.n)
195
202
  else:
@@ -225,6 +232,7 @@ class MediaFile:
225
232
  total=100,
226
233
  position=1,
227
234
  desc=f"Stream {index + 1}/{len(self.streams['audio'].values())}",
235
+ bar_format=TQDM_BAR_FORMAT,
228
236
  ) as pbar:
229
237
  for progress in fun():
230
238
  pbar.update(progress - pbar.n)
@@ -1 +1 @@
1
- __version__ = "1.29.0"
1
+ __version__ = "1.29.2"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: ffmpeg-normalize
3
- Version: 1.29.0
3
+ Version: 1.29.2
4
4
  Summary: Normalize audio via ffmpeg
5
5
  Home-page: https://github.com/slhck/ffmpeg-normalize
6
6
  Author: Werner Robitza
@@ -19,6 +19,7 @@ Classifier: Programming Language :: Python :: 3.8
19
19
  Classifier: Programming Language :: Python :: 3.9
20
20
  Classifier: Programming Language :: Python :: 3.10
21
21
  Classifier: Programming Language :: Python :: 3.11
22
+ Classifier: Programming Language :: Python :: 3.12
22
23
  Requires-Python: >=3.8
23
24
  Description-Content-Type: text/markdown
24
25
  License-File: LICENSE
@@ -598,6 +599,18 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
598
599
  # Changelog
599
600
 
600
601
 
602
+ ## v1.29.2 (2024-11-18)
603
+
604
+ * Fix: show percentage with two decimal digits in progress.
605
+
606
+ * Chore: add python 12.
607
+
608
+
609
+ ## v1.29.1 (2024-10-22)
610
+
611
+ * Fix: override argparse usage.
612
+
613
+
601
614
  ## v1.29.0 (2024-10-14)
602
615
 
603
616
  * Add option to set audio channels directly.
@@ -1,16 +1,16 @@
1
1
  ffmpeg_normalize/__init__.py,sha256=aAhlk93ZE6SQcWUDzZQcw9vJh0bJcKEUNFGhVc5ZIto,453
2
- ffmpeg_normalize/__main__.py,sha256=ErDBLeHLEKke1Ub_Aj5ZmuxFKhPHEMV3ZKHNs2-E7Oc,18427
2
+ ffmpeg_normalize/__main__.py,sha256=vIVZAKPyI7zO9K22FYeaE-q_4JeZAQg1xlQc0739Gqk,18603
3
3
  ffmpeg_normalize/_cmd_utils.py,sha256=A6quxjOl5tLHxgcs7SdMXzuOCP_JjUTzL1iUD4G7DJk,5361
4
4
  ffmpeg_normalize/_errors.py,sha256=brTQ4osJ4fTA8wnyMPVVYfGwJ0wqeShRFydTEwi_VEY,48
5
5
  ffmpeg_normalize/_ffmpeg_normalize.py,sha256=mARUHvgLwcs0yGsuDkkDZYqE2JJmnEZtkADKUS4giRc,10556
6
6
  ffmpeg_normalize/_logger.py,sha256=3Ap4Fxg7xGrzz7h4IGuNEf0KKstx0Rq_eLbHPrHzcrI,1841
7
- ffmpeg_normalize/_media_file.py,sha256=FgLHy1lwfvI1EpEvLioyBD30Pj4XzMYUceJ3-J_mb80,16434
7
+ ffmpeg_normalize/_media_file.py,sha256=ym9t_J3Z_jCiL0YMGwk0-E0o3qg858d4-3JX7hAiFmk,16651
8
8
  ffmpeg_normalize/_streams.py,sha256=5zLlSK2vMTBs0HzBTmI5UiJVqSp1Nk19TZXpxNtjkIA,19973
9
- ffmpeg_normalize/_version.py,sha256=eVlxQqZ7oGpvnt3LTlQf3uAGXW6kYUOGvlYLZn1ordc,23
9
+ ffmpeg_normalize/_version.py,sha256=x7VlhF5gtHvQF5azFyGSActBYj8D2TvquvRXi3DdQdA,23
10
10
  ffmpeg_normalize/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
11
- ffmpeg_normalize-1.29.0.dist-info/LICENSE,sha256=zeqAHGWrSIwdPHsZMZv1_N0gGFO1xxjcZEz9CplR4EM,1086
12
- ffmpeg_normalize-1.29.0.dist-info/METADATA,sha256=t0YoTmIh9Mt5SK5zXb4Wsx-PIjZzJEMOpaAhnShHPlc,56093
13
- ffmpeg_normalize-1.29.0.dist-info/WHEEL,sha256=fS9sRbCBHs7VFcwJLnLXN1MZRR0_TVTxvXKzOnaSFs8,110
14
- ffmpeg_normalize-1.29.0.dist-info/entry_points.txt,sha256=X0EC5ptb0iGOxrk3Aa65dVQtvUixngLd_2-iAtSixdc,68
15
- ffmpeg_normalize-1.29.0.dist-info/top_level.txt,sha256=wnUkr17ckPrrU1JsxZQiXbEBUnHKsC64yck-MemEBuI,17
16
- ffmpeg_normalize-1.29.0.dist-info/RECORD,,
11
+ ffmpeg_normalize-1.29.2.dist-info/LICENSE,sha256=zeqAHGWrSIwdPHsZMZv1_N0gGFO1xxjcZEz9CplR4EM,1086
12
+ ffmpeg_normalize-1.29.2.dist-info/METADATA,sha256=En7t5Ll7zA6K2mbO9nCu5DqjZhHZJlyIPHZlZoW-N6M,56315
13
+ ffmpeg_normalize-1.29.2.dist-info/WHEEL,sha256=fS9sRbCBHs7VFcwJLnLXN1MZRR0_TVTxvXKzOnaSFs8,110
14
+ ffmpeg_normalize-1.29.2.dist-info/entry_points.txt,sha256=X0EC5ptb0iGOxrk3Aa65dVQtvUixngLd_2-iAtSixdc,68
15
+ ffmpeg_normalize-1.29.2.dist-info/top_level.txt,sha256=wnUkr17ckPrrU1JsxZQiXbEBUnHKsC64yck-MemEBuI,17
16
+ ffmpeg_normalize-1.29.2.dist-info/RECORD,,