Skip to content

Conversation

@david-cortes-intel
Copy link
Contributor

Description

As part of the updates for changes in sklearn1.8's logistic regression, some tests appear to have been adapted only partially. This PR removes a failing test for functionality that's being removed in sklearn1.8 and which is currently causing CI failures on the nightly jobs.


Checklist:

Completeness and readability

  • Git commit message contains an appropriate signed-off-by string (see CONTRIBUTING.md for details).
  • I have resolved any merge conflicts that might occur with the base branch.

Testing

  • All CI jobs are green or I have provided justification why they aren't.

@david-cortes-intel
Copy link
Contributor Author

/azp run Nightly

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@codecov
Copy link

codecov bot commented Nov 21, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.

Flag Coverage Δ
azure 80.49% <ø> (ø)
github 82.08% <ø> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.
see 3 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@david-cortes-intel
Copy link
Contributor Author

Looks like it fixed the issue, but note that the CI jobs still fail due to other unrelated reasons.

@icfaust
Copy link
Contributor

icfaust commented Nov 21, 2025

At that point, a pytest.skipif(not sklearn_check_version("1.8"), reason="no longer relevant in sklearn >1.8") may be clearer

@david-cortes-intel
Copy link
Contributor Author

At that point, a pytest.skipif(not sklearn_check_version("1.8"), reason="no longer relevant in sklearn >1.8") may be clearer

Modified to use skipif.

LogisticRegression(multi_class="ovr"),
3,
marks=pytest.mark.skipif(
not sklearn_check_version("1.8"),
Copy link
Contributor

Choose a reason for hiding this comment

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

We should do the opposite skip if sklearn_check_version("1.8")

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, fixed.

@david-cortes-intel
Copy link
Contributor Author

At that point, a pytest.skipif(not sklearn_check_version("1.8"), reason="no longer relevant in sklearn >1.8") may be clearer

Actually not possible, because it requires instantiating the model objects with the removed arguments before the test is skipped.

),
]
if not sklearn_check_version("1.8")
else [(LogisticRegression(solver="liblinear"), 2)]
Copy link
Contributor

@avolkov-intel avolkov-intel Nov 26, 2025

Choose a reason for hiding this comment

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

Why do we need to remove this test, I think it's not deprecated

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The test is checking that it fails to convert the model. This would work fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

sklearn-patch sklearn patching

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants