Commit 862f0e3
committed
Remove ffmpeg-python and use subprocess exclusively for decryption
The ffmpeg-python library has a known bug that prevents map_metadata and
map_chapters from working correctly. Since the fix hasn't been merged in
over 2 years, we're switching to subprocess exclusively.
## Issue
ffmpeg-python doesn't properly handle -map_metadata and -map_chapters
parameters. When passed as kwargs, they don't get translated to the
correct FFmpeg command-line arguments.
Issue: kkroening/ffmpeg-python#463
PR (unmerged): kkroening/ffmpeg-python#814
## Changes
### Simplified decrypt_aaxc()
- Removed ffmpeg-python implementation attempt
- Removed fallback pattern (_decrypt_aaxc_subprocess helper)
- Now uses subprocess directly for all decryption
- Added comment explaining why we don't use ffmpeg-python
- Cleaner, simpler code with no hybrid approach needed
### Updated imports
- Removed ffmpeg import from src/downloader.py
- Removed ffmpeg-python from requirements.txt
## Benefits
1. **Reliable**: Subprocess approach is proven to work
2. **Simpler**: No fallback logic, no hybrid approach
3. **Maintainable**: Direct FFmpeg command construction is easier to debug
4. **Cleaner dependencies**: One less package to maintain
The subprocess implementation gives us precise control over the FFmpeg
command and handles all our use cases correctly (metadata, chapters,
cover art embedding).1 parent b5d203b commit 862f0e3
2 files changed
Lines changed: 2 additions & 72 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
11 | 10 | | |
12 | 11 | | |
13 | 12 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
8 | 7 | | |
9 | 8 | | |
10 | 9 | | |
| |||
355 | 354 | | |
356 | 355 | | |
357 | 356 | | |
358 | | - | |
359 | | - | |
360 | | - | |
361 | | - | |
362 | | - | |
363 | | - | |
364 | | - | |
365 | | - | |
366 | | - | |
367 | | - | |
368 | | - | |
369 | | - | |
370 | | - | |
371 | | - | |
372 | | - | |
373 | | - | |
374 | | - | |
375 | | - | |
376 | | - | |
377 | | - | |
378 | | - | |
379 | | - | |
380 | | - | |
381 | | - | |
382 | | - | |
383 | | - | |
384 | | - | |
385 | | - | |
386 | | - | |
387 | | - | |
388 | | - | |
389 | | - | |
390 | | - | |
391 | | - | |
392 | | - | |
393 | | - | |
394 | | - | |
395 | | - | |
396 | | - | |
397 | | - | |
398 | | - | |
399 | | - | |
400 | | - | |
401 | | - | |
402 | | - | |
403 | | - | |
404 | | - | |
405 | | - | |
406 | | - | |
407 | | - | |
408 | | - | |
409 | | - | |
410 | | - | |
411 | | - | |
412 | | - | |
413 | | - | |
414 | | - | |
415 | | - | |
416 | | - | |
417 | | - | |
418 | | - | |
419 | | - | |
420 | | - | |
421 | | - | |
422 | | - | |
423 | | - | |
424 | | - | |
425 | | - | |
426 | | - | |
427 | 357 | | |
| 358 | + | |
| 359 | + | |
428 | 360 | | |
429 | 361 | | |
430 | 362 | | |
| |||
452 | 384 | | |
453 | 385 | | |
454 | 386 | | |
455 | | - | |
456 | 387 | | |
457 | 388 | | |
458 | 389 | | |
| |||
0 commit comments