Skip to content

Fix test timeout#4285

Merged
rasapala merged 1 commit into
mainfrom
timout_handling
Jun 11, 2026
Merged

Fix test timeout#4285
rasapala merged 1 commit into
mainfrom
timout_handling

Conversation

@rasapala

Copy link
Copy Markdown
Collaborator

🛠 Summary

JIRA CVS-188296
This PR fixes flakiness in TestInvalidProxyTimeout by removing dependency on external network topology.
Previously, the test used conditional logic based on host proxy settings and could still target the real Hugging Face endpoint, causing non-deterministic timing failures across environments.
The test now always clears https_proxy and forces HF_ENDPOINT to https://192.0.2.1/ (RFC 5737 TEST-NET-1, non-routable), ensuring clone failure is deterministic and the timeout path is consistently exercised.
Also corrected the assertion message from “1ms” to “1s” to match the configured timeout value (1000 ms).

🧪 Checklist

  • Unit tests added.
  • The documentation updated.
  • Change follows security best practices.
    ``

@rasapala rasapala requested review from atobiszei and Copilot and removed request for Copilot June 11, 2026 09:45
@rasapala rasapala requested a review from przepeck June 11, 2026 09:45
if (!hostHadProxy) {
eGuard.set("HF_ENDPOINT", "https://192.0.2.1/");
}
eGuard.set("HF_ENDPOINT", "https://192.0.2.1/");

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

You are testing different thing now - inside our CI we have a proper HF_ENDPOINT, and this test was supposed to test if timeout will trigger if we set up proxy wrong.

@rasapala rasapala changed the title Fix test timout Fix test timeout Jun 11, 2026
@rasapala rasapala merged commit d4d1403 into main Jun 11, 2026
2 checks passed
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.

3 participants