Commit a44ca41
committed
Fix test
Root cause: The skip guard in tests/test_new_modules.py only blocked XGBoost >= 3 on macOS, but the CI logs show XGBoost 2.x (installed by the <3 pin) crashes with the identical _meta_from_numpy segfault on macOS arm64. The >= 3 threshold was incorrect.
Fix (lines 28-44): Moved the macOS check to a top-level elif that skips all XGBoost tests on Darwin regardless of version, before even attempting the import:
elif platform.system() == "Darwin":
_XGB_AVAILABLE = False
_XGB_SKIP_REASON = "xgboost segfaults in _meta_from_numpy during sklearn CV on macOS arm64 (all versions)"
The requirements-dev.txt pin (xgboost>=1.7,<3) and n_jobs=1 in classifiers.py can stay as-is. The XGBoost tests will now be correctly skipped on all three failing macOS jobs (3.11, 3.12, 3.13) instead of reaching the segfault.1 parent d90fb9e commit a44ca41
1 file changed
Lines changed: 5 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
30 | | - | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
31 | 34 | | |
32 | 35 | | |
33 | 36 | | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | 37 | | |
40 | | - | |
| 38 | + | |
41 | 39 | | |
42 | 40 | | |
43 | 41 | | |
| |||
0 commit comments