Skip to content

Respect configured lossy conversion bitrate#960

Open
TimoStolz wants to merge 1 commit intonathom:devfrom
TimoStolz:fix-conversion-lossy-bitrate
Open

Respect configured lossy conversion bitrate#960
TimoStolz wants to merge 1 commit intonathom:devfrom
TimoStolz:fix-conversion-lossy-bitrate

Conversation

@TimoStolz
Copy link
Copy Markdown

@TimoStolz TimoStolz commented Apr 12, 2026

Problem

When conversion is configured for OPUS with lossy_bitrate = 160, streamrip still passes the codec default bitrate to ffmpeg.

Reproduction:

  1. Set conversion to OPUS and lossy_bitrate = 160 in the config.
  2. Run rip -vv <url>.
  3. The debug output currently reports FFmpeg codec extra argument: -b:a 128k, and the generated ffmpeg command contains -b:a 128k instead of the configured -b:a 160k.

Summary

  • pass conversion.lossy_bitrate into lossy converters during track conversion
  • make OPUS and AAC generate bitrate ffmpeg args from the configured value
  • add conversion tests covering lossy and lossless converter behavior

Tests

  • python -m pytest
  • python -m black --check streamrip/converter.py streamrip/media/track.py tests/test_converter.py

Note: ruff is not installed in the local environment, so ruff check could not be run here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant