-
Notifications
You must be signed in to change notification settings - Fork 589
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
[DO NOT MERGE] [API server] consistent module path of server and cli #4884
base: master
Are you sure you want to change the base?
Conversation
/quicktest-core |
1 similar comment
/quicktest-core |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this makes sense. @Michaelvll should also review.
Signed-off-by: Aylei <[email protected]>
Signed-off-by: Aylei <[email protected]>
Thanks for @Michaelvll 's idea, this PR is now greatly simplified and handles |
Signed-off-by: Aylei <[email protected]>
subprocess.Popen(cmd, | ||
shell=True, | ||
start_new_session=True, | ||
cwd=working_dir) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ahh, this could be a bit dangerous, if a user specified a relative path for SKYPILOT_CONFIG=./config.yaml
. Does this mean the config path will not be loaded locally?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could use python -P
CLI option, but this is only available in 3.11 and higher.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great catch! Will investigate more
close #4801
Tested manually, checked whether the module in current working dir is used:
This branch, the installed module is used instead of current dir, which is expected:
This branch, but launch with
python -m sky.cli api start
:Master branch, start raise an error, indicates the local dir is used:
Also tested the case that
skyserver
is not installed:Tested (run the relevant ones):
bash format.sh
pytest tests/test_smoke.py
pytest tests/test_smoke.py::test_fill_in_the_name
conda deactivate; bash -i tests/backward_compatibility_tests.sh