[core] fix test_placement_group_3_client_mode by changing url parser#61506
Draft
ZacAttack wants to merge 1 commit intoray-project:masterfrom
Draft
[core] fix test_placement_group_3_client_mode by changing url parser#61506ZacAttack wants to merge 1 commit intoray-project:masterfrom
ZacAttack wants to merge 1 commit intoray-project:masterfrom
Conversation
The test seems to fail because the dashboard agent keeps crashing. Looking at it, it seems to be because if you use host:port when hitting the urlparse(url).scheme that will evaluate to true. Which means the proper http scheme won't get pre-appended to the address. Signed-off-by: zac <zac@anyscale.com>
Contributor
There was a problem hiding this comment.
Code Review
The pull request effectively addresses the reported issue by replacing the urlparse scheme check with a more direct startswith method for validating HTTP/HTTPS prefixes. This change is a clear and concise solution to prevent incorrect scheme detection and ensures that the dashboard HTTP address is always correctly prefixed. The removal of the unused urlparse import is also appropriate.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Problem:
test_placement_group_3_client_mode is failing because the dashboard keeps crashing.
Looking at it, it seems to be because if you use host:port when hitting the urlparse(url).scheme that will evaluate to true. Which means the proper http scheme won't get pre-appended to the address.
Solution:
Replace the url parser with string match 'startswith' and call it a day!
Related issues
Additional information