Skip to content

Remove unused flush_right#5358

Merged
albertvillanova merged 1 commit into
huggingface:mainfrom
albertvillanova:fu-5350
Mar 24, 2026
Merged

Remove unused flush_right#5358
albertvillanova merged 1 commit into
huggingface:mainfrom
albertvillanova:fu-5350

Conversation

@albertvillanova

@albertvillanova albertvillanova commented Mar 24, 2026

Copy link
Copy Markdown
Member

Remove unused flush_right.

Follow-up to:

This PR removes the flush_right utility function and its associated tests from the codebase. This simplifies the utilities and test files by eliminating unused or unnecessary code.

Changes

Removals related to flush_right:

  • Removed the flush_right function from trl/trainer/utils.py.
  • Deleted the TestFlushRight test class and all related test cases from tests/test_utils.py.
  • Removed the import of flush_right from tests/test_utils.py.

Note

Low Risk
Low risk cleanup that removes an unused utility and its unit tests; behavior is unchanged unless downstream code relied on the previously exported symbol.

Overview
Removes the unused flush_right helper from trl/trainer/utils.py and drops its import and the entire TestFlushRight test suite from tests/test_utils.py.

This PR is purely a cleanup to reduce dead utility/test code and simplify the utils surface area.

Written by Cursor Bugbot for commit 7ecc924. This will update automatically on new commits. Configure here.

@HuggingFaceDocBuilderDev

Copy link
Copy Markdown

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

@albertvillanova albertvillanova merged commit ffa14ee into huggingface:main Mar 24, 2026
12 checks passed
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.

3 participants