Skip to content

Fix pad token id issue for transformers v5 support#1058

Merged
vaibhavjindal merged 1 commit intotransformers-5.0.0rc1from
fix-pad-token-id
Feb 3, 2026
Merged

Fix pad token id issue for transformers v5 support#1058
vaibhavjindal merged 1 commit intotransformers-5.0.0rc1from
fix-pad-token-id

Conversation

@vaibhavjindal
Copy link
Collaborator

@vaibhavjindal vaibhavjindal commented Feb 3, 2026

Summary

Fix multiple failing monkey_patch tests for transformers v5. The tests failed because of huggingface/transformers#41541.

These changes are backward compatible.

This change fixes the following failing tests:

FAILED test/transformers/test_monkey_patch.py::test_apply_liger_kernel_to_instance_for_qwen3_vl_moe_for_conditional_generation - AttributeError: 'Qwen3VLMoeTextConfig' object has no attribute 'pad_token_id'
FAILED test/transformers/test_monkey_patch.py::test_apply_liger_kernel_to_instance_for_qwen3_vl_moe - AttributeError: 'Qwen3VLMoeTextConfig' object has no attribute 'pad_token_id'
FAILED test/transformers/test_monkey_patch.py::test_apply_liger_kernel_to_instance_for_qwen3_vl_moe_text - AttributeError: 'Qwen3VLMoeTextConfig' object has no attribute 'pad_token_id'
FAILED test/transformers/test_monkey_patch.py::test_apply_liger_kernel_to_instance_for_llama4_for_conditional_generation - AttributeError: 'Llama4Config' object has no attribute 'pad_token_id'
FAILED test/transformers/test_monkey_patch.py::test_apply_liger_kernel_to_instance_for_glm4v - AttributeError: 'Glm4vTextConfig' object has no attribute 'pad_token_id'

Fixes #1059.

Testing Done

  • Hardware Type:
  • run make test to ensure correctness
  • run make checkstyle to ensure code style
  • run make test-convergence to ensure convergence

@vaibhavjindal vaibhavjindal changed the base branch from main to transformers-5.0.0rc1 February 3, 2026 01:05
@vaibhavjindal vaibhavjindal marked this pull request as ready for review February 3, 2026 01:14
@vaibhavjindal
Copy link
Collaborator Author

@Tcc0403 @shimizust @Mecoli1219 for review

Copy link
Collaborator

@Tcc0403 Tcc0403 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks LGTM

@vaibhavjindal vaibhavjindal merged commit 80801d5 into transformers-5.0.0rc1 Feb 3, 2026
@vaibhavjindal vaibhavjindal deleted the fix-pad-token-id branch February 3, 2026 01:21
@vaibhavjindal
Copy link
Collaborator Author

#1059

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.

2 participants