ITADN

CI warns with dev dependencies: FutureWarning: `device` is deprecated and will be removed in version 5.18 for `compute_default_rope_parameters`

#6584Openalbertvillanova 创建于 20 天前
A
albertvillanovacommented
CI emits a new warning with dev dependencies (`transformers` installed from `main`): - Experimental trainers tests: https://github.com/huggingface/trl/actions/runs/30515263172/job/90783545090 - Core trainers tests: https://github.com/huggingface/trl/actions/runs/30515263177/job/90783545208 > FutureWarning: `device` is deprecated and will be removed in version 5.18 for `compute_default_rope_parameters`. ```python /__w/trl/trl/.venv/lib/python3.13/site-packages/transformers/models/llama/modeling_llama.py:88: FutureWarning: `device` is deprecated and will be removed in version 5.18 for `compute_default_rope_parameters`. inv_freq, self.attention_scaling = rope_init_fn(self.config, device=device) ``` The warning is raised at model init, so it fires across most architectures used in the test suite: ``` cohere, cohere2, deepseek_v3, gemma, gemma2, gemma3, gemma4, glm4_moe, gpt_neox, lfm2, llama, mistral, olmo3, phi3, qwen2, qwen2_5_vl, qwen2_vl, qwen3, qwen3_5, qwen3_5_moe, qwen3_moe, qwen3_vl ``` Tests still pass, but this single warning now accounts for essentially all of the warnings reported in the dev-dependency jobs, drowning out any other warning signal: | Job | Total warnings | Distinct messages in the pytest warnings summary | | --- | --- | --- | | Experimental trainers (dev deps) | 437 | 1 (this warning, ~427 across 11 location blocks) | | Core trainers (dev deps) | 859 | 1 (this warning, ~787 across 23 location blocks) | For comparison, the same test suite run with released dependencies reports **no warnings at all**: ``` ================= 545 passed, 14 skipped in 548.15s (0:09:08) ================== ```
2 条评论