Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CLI] Disable --ip with --refresh when calling sky status to avoid additional empty lines in output #2691

Merged
merged 4 commits into from
Oct 21, 2023

Conversation

cblmemo
Copy link
Collaborator

@cblmemo cblmemo commented Oct 11, 2023

If --ip is used with --refresh, there will be an additional new line in the output (which is caused by the rich progress bar. It will make commands like curl $(sky status --ip <cluster> -r) to report illegal format (curl: (3) URL using bad/illegal format or missing URL). To reproduce:

$ echo "a$(sky status cluster-0 --ip)b"
a33.127.121.7b
$ echo "a$(sky status cluster-0 -r --ip)b"
a
33.127.121.7b
$ ip=$(sky status --ip cluster-0 -r); echo "a$ip b"; curl $ip
a
33.127.121.7 b
curl: (3) URL using bad/illegal format or missing URL

This PR disabled such option.

Tested (run the relevant ones):

  • Code formatting: bash format.sh
  • Any manual or new tests for this PR (please specify below)
  • All smoke tests: pytest tests/test_smoke.py
  • Relevant individual smoke tests: pytest tests/test_smoke.py::test_fill_in_the_name
  • Backward compatibility tests: bash tests/backward_comaptibility_tests.sh

sky/cli.py Outdated Show resolved Hide resolved
cblmemo and others added 2 commits October 20, 2023 17:04
Co-authored-by: Zongheng Yang <zongheng.y@gmail.com>
@cblmemo cblmemo merged commit 0dc5b32 into master Oct 21, 2023
18 checks passed
@cblmemo cblmemo deleted the disable-ip-refresh branch October 21, 2023 00:37
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.

None yet

2 participants