Skip to content

Fix CI with dev dependencies for Llava models#5499

Merged
albertvillanova merged 5 commits intohuggingface:mainfrom
albertvillanova:fix-5497
Apr 20, 2026
Merged

Fix CI with dev dependencies for Llava models#5499
albertvillanova merged 5 commits intohuggingface:mainfrom
albertvillanova:fix-5497

Conversation

@albertvillanova
Copy link
Copy Markdown
Member

@albertvillanova albertvillanova commented Apr 10, 2026

Fix CI with dev dependencies for Llava models, after the merge in transformers of this PR:

Fix #5497.

This PR updates the test logic in both test_sft_trainer.py and test_dpo_trainer.py to support changes in the model parameter naming introduced in transformers dev (version 5.6.0 and above). The changes ensure that the tests correctly handle both the old and new parameter names, improving compatibility across different versions of the transformers library.

Changes

Test compatibility improvements:

  • Updated parameter name checks in test_train_vlm in tests/test_sft_trainer.py to handle both pre-5.6.0 and 5.6.0+ versions of the transformers library for Llava and LlavaNext models.
  • Made equivalent updates in test_train_vlm in tests/test_dpo_trainer.py for Llava and LlavaNext models to ensure compatibility with the new naming conventions in transformers 5.6.0 and above.

Note

Low Risk
Low risk since changes are confined to test expectations and CI behavior, but they may re-enable previously flaky Llava/LlavaNext runs depending on upstream transformers dev changes.

Overview
Removes the xfail gating for tiny-Llava* VLM cases in both test_sft_trainer.py and test_dpo_trainer.py, so these models run normally even on transformers dev builds.

Updates the VLM parameter-change assertion skip list to recognize the new Llava/LlavaNext vision-tower parameter names in transformers>=5.6.0 (while keeping the old names for earlier versions), preventing false CI failures due to upstream renames (see #5497).

Reviewed by Cursor Bugbot for commit 55f4200. Bugbot is set up for automated code reviews on this repo. 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
Copy link
Copy Markdown
Member Author

As it seems the underlying issue is a bug upstream (pending to be fixed), I'm closing this PR in favor of:

@albertvillanova
Copy link
Copy Markdown
Member Author

After further investigation, the transformers team confirmed we need indeed to change the naming on our side: huggingface/transformers#45448 (comment)

You indeed need to change the hardcoded name on your side in this case

I'm reopening this PR.

@albertvillanova albertvillanova merged commit 06244b0 into huggingface:main Apr 20, 2026
9 of 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.

CI fails with dev dependencies for Llava models: AssertionError: Param is not updated

3 participants