Commit Graph
29 Commits
Author SHA1 Message Date
02d8fb9784 [CI] check_bad_commit: use EFS cache to avoid Xet FUSE OOM (exit 137) (#49273)
* [CI] check_bad_commit: use EFS cache to avoid Xet FUSE OOM (exit 137)

Temporary workaround matching huggingface/transformers-ci#184: set
HF_HOME=/mnt/efs_cache when the mount is present so pytest loads large
model weights from EFS instead of Xet FUSE, avoiding the cgroup RAM
exhaustion that kills the process with exit 137.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* simplify comment

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

---------

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-10-02 22:59:34 +02:00
Tarek Ziade f441076206 QA: applied ruff rule PLW1514 (#48990) 2026-09-22 06:49:19 +00:00
d0e91c7ff1 CI: use a single function for GH calls (#47474)
* use a single function for GH calls

* check token before loop

* Add pre-flight token/quota check and per-request rate-limit logging to github_utils

- Add _log_token_status(): calls /rate_limit once before the retry loop (no quota
  consumed). Fails immediately if: CI env with no token, token rejected (401), or
  quota already exhausted (remaining=0). 401 with vs. without token gives distinct
  actionable error messages.
- Add _log_rate_limit_headers(): prints limit/used/remaining/reset on every request
  attempt, labeled [initial] / [retry N/M]. Skipped on 401 (GitHub omits those
  headers on auth failures).
- Remove _is_expired_or_bad_token(): pre-flight check catches bad tokens earlier;
  401s in the retry loop fall through to the generic fail-hard with the raw body.
- Update tests: remove IsExpiredOrBadTokenTest (function deleted), add
  LogTokenStatusTest covering all _log_token_status failure modes, patch
  _log_token_status in GithubRequestTest.setUp so mock responses are not consumed
  by the pre-flight call.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* Fix stale comments about get_github_json error handling

get_github_json now raises RuntimeError on error responses (rate limiting,
auth failures, etc.) rather than returning an error dict. Update comments
in notification_service.py and check_bad_commit.py that incorrectly described
the old behaviour, while keeping the defensive .get() calls which guard
against unexpected response shapes.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* format

* fix

---------

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-07-28 16:03:35 +02:00
Yih-Darandydshieh 5b32a41f56 Use --flake-runs=1 in check_bad_commit.py for PR comment CI (#47522)
* 1 instead of 4

* 1 instead of 4

---------

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2026-07-24 17:01:54 +02:00
7d6a50be1a fix: harden check_bad_commit.py against GitHub API rate limits and error responses (#46321)
* fix: pass GitHub token to API calls in check_bad_commit.py to avoid rate limiting

Adds a `--github_token` argument (default None) and passes it as an
Authorization header to all `requests.get` calls in `get_commit_info`,
raising the rate limit from 60 to 5000 req/hour when a token is provided.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix: use consistent GitHub API header format (Bearer + Accept)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* ci: pass GITHUB_TOKEN to check_bad_commit.py in workflow

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* style

* more secure

* fix: guard commit_info parents access against error API responses

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix: consistent early-return schema and pass GitHub token via env var

- Add `parent: None` to the early-return dict when commit is None, so the
  return schema is consistent for all callers
- Pass GITHUB_TOKEN as an env var instead of a CLI arg to avoid potential
  token exposure in the process list; script falls back to GITHUB_TOKEN env
  var when --github_token is not supplied

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* style

---------

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-01 15:53:23 +02:00
Yih-Darandydshieh 7a3806ca0c Normalize CUDA OOM errors when comparing commit failures in check_bad_commit (#46322)
fix

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2026-06-01 13:46:33 +02:00
Yih-Darandydshieh e3f7cc3b4a Use multi runners to check new failing tests in a CI run (#45032)
* multi runners

* multi runners

---------

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2026-03-26 19:58:10 +01:00
Tarek Ziade efdcbc77ea Fix return value - fixes #44238 (#44240) 2026-02-24 21:02:57 +08:00
Yih-Darandydshieh 0dda1ffbf3 Improve new failing test analysis for PR comment CI (#44033)
tryyyy!

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2026-02-16 16:02:13 +08:00
Yih-Darandydshieh 8c403da7ae Fix KeyError in check_bad_commit.py (#43655)
fix

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2026-01-31 19:50:57 +01:00
Yih-Darandydshieh 2ff1d4f0ec Add explicit commit info to PR comment CI feedback (#43635)
* fix

* fix

* fix

* fix

---------

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2026-01-31 12:33:49 +01:00
Yih-Darandydshieh 30088d05a7 Improve new failures reporting (#43628)
* better

* format

---------

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2026-01-30 15:35:20 +01:00
Yih-Darandydshieh dfe30827b8 Revert utils files changes from PR #42845 (#43507)
Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2026-01-26 21:50:04 +01:00
Omkar KabdeandLucain db1e6f1e7f Remove requests code (#42845)
* setup, workflow and utils files

* src core files

* use get_session instead of httpx

* fix code quality - remove unused imports

* utils and prevous-http-used and cli

* style changes

* use httpx for non-HF images

* get_session for HF images

* change docstrings

* revert formatting - 1

* revert formatting - 2

* docstrings fixes

* revert formatting - 3

* docstring fixes

* fix failing test

* Update src/transformers/pipelines/image_to_image.py

* Update src/transformers/testing_utils.py

* fix modular generation check

* fix consistency

* Apply suggestions from code review

* Update src/transformers/models/idefics2/modeling_idefics2.py

* Update src/transformers/models/idefics3/modeling_idefics3.py

---------

Co-authored-by: Lucain <lucainp@gmail.com>
2026-01-23 11:50:53 +01:00
Cyril Vallez 3a275d3581 [style] Rework ruff rules and update all files (#43144)
* improve ruff setup

* fix

* ruff was already bumped, no need to remove

* remove F402

* remove one more

* one more

* latest ruff

* fix

* more removed rules

* last removed exceptions

* fix copies again

* fix

* fix

* all typing

* fix copies

* consistency

* fix

* oupsi

* more precise modular converter

* doc

* last fix
2026-01-08 10:26:14 +01:00
Yih-Darandydshieh 8fb854cac8 Run slow v2 (#41914)
* Super

* Super

* Super

* Super

---------

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2025-11-01 19:40:40 +01:00
Yih-Darandydshieh c27efe6e65 further reducing flakiness in utils/check_bad_commit.py (#41658) (#41815)
* 111

* fix

* fix

* fix

---------

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2025-10-24 11:36:01 +02:00
307c523854 further improve utils/check_bad_commit.py (#41658) (#41690)
* fix

* Update utils/check_bad_commit.py

Co-authored-by: Anton Vlasjuk <73884904+vasqu@users.noreply.github.com>

* fix

* fix

* fix

---------

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
Co-authored-by: Anton Vlasjuk <73884904+vasqu@users.noreply.github.com>
2025-10-17 23:07:00 +02:00
Yih-Darandydshieh 6344371a91 improve utils/check_bad_commit.py (#41658)
* robust

* robust

* robust

---------

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2025-10-16 15:51:19 +00:00
Yih-Darandydshieh 369c99d0ce Avoid utils/check_bad_commit.py failing due to rate limit (requesting api.github.com) (#39918)
fix

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2025-08-05 21:52:20 +02:00
Yuanyuan Chen 822c5e45b2 Fix pylint warnings (#39477)
* Fix pylint warnings

Signed-off-by: cyy <cyyever@outlook.com>

* Fix variable names

Signed-off-by: cyy <cyyever@outlook.com>

---------

Signed-off-by: cyy <cyyever@outlook.com>
2025-07-21 12:38:05 +00:00
Yih-Darandydshieh d0c9c66d1c new failure CI reports for all jobs (#38298)
* new failures

* report_repo_id

* report_repo_id

* report_repo_id

* More fixes

* More fixes

* More fixes

* ruff

---------

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2025-05-24 19:15:02 +02:00
Yih-Darandydshieh feec294dea CI reporting improvements (#38230)
update

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2025-05-20 19:34:58 +02:00
Yih-Darandydshieh 582d5e0e11 fix check_bad commit.py gives wrong results (#38107)
fix

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2025-05-13 16:58:22 +02:00
Yih-Darandydshieh b016de1ae4 Fix utils/check_bad_commit.py (#37272)
fix

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2025-04-04 12:18:20 +02:00
Yih-Darandydshieh 6300212946 Fix utils/check_bad_commit.py (for auto ping in CI) (#34943)
* fix

* fix

---------

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2024-11-28 15:34:38 +01:00
Yih-Darandydshieh 9360f1827d Tiny update after #34383 (#34404)
* update

* update

* update

---------

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2024-10-28 12:01:05 +01:00
Yih-Darandydshieh a308d28d39 [auto. ping] Avoid sending empty info + add more team members (#34383)
* update

* update

---------

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2024-10-24 19:07:23 +02:00
Yih-Darandydshieh fce1fcfe71 Ping team members for new failed tests in daily CI (#34171)
* ping

* fix

* fix

* fix

* remove runner

* update members

---------

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
2024-10-17 16:11:52 +02:00