-
Notifications
You must be signed in to change notification settings - Fork 893
support python 3.12 and 3.13 #5304
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
Merged
Merged
Changes from 1 commit
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -10,6 +10,8 @@ | |
|
|
||
| install_requires = [ | ||
| 'wheel<0.46.0', # https://github.com/skypilot-org/skypilot/issues/5153 | ||
| 'setuptools', # TODO: match version to pyproject.toml once #5153 is fixed | ||
| 'pip', | ||
| 'cachetools', | ||
| # NOTE: ray requires click>=7.0. | ||
| 'click >= 7.0', | ||
|
|
@@ -115,7 +117,7 @@ | |
| 'azure-mgmt-compute>=33.0.0', | ||
| 'azure-storage-blob>=12.23.1', | ||
| 'msgraph-sdk', | ||
| ] + local_ray, | ||
| ], | ||
| # We need google-api-python-client>=2.69.0 to enable 'discardLocalSsd' | ||
| # parameter for stopping instances. Reference: | ||
| # https://github.com/googleapis/google-api-python-client/commit/f6e9d3869ed605b06f7cbf2e8cf2db25108506e6 | ||
|
|
@@ -130,7 +132,7 @@ | |
| 'lambda': [], # No dependencies needed for lambda | ||
| 'cloudflare': aws_dependencies, | ||
| 'scp': local_ray, | ||
| 'oci': ['oci'] + local_ray, | ||
| 'oci': ['oci'], | ||
| # Kubernetes 32.0.0 has an authentication bug: https://github.com/kubernetes-client/python/issues/2333 # pylint: disable=line-too-long | ||
| 'kubernetes': ['kubernetes>=20.0.0,!=32.0.0', 'websockets'], | ||
| 'remote': remote, | ||
|
|
@@ -156,10 +158,21 @@ | |
| ] + aws_dependencies | ||
| } | ||
|
|
||
| # Nebius needs python3.10. If python 3.9 [all] will not install nebius | ||
| # Calculate which clouds should be included in the [all] installation. | ||
| clouds_for_all = set(extras_require) | ||
| clouds_for_all.remove('remote') | ||
|
|
||
| if sys.version_info < (3, 10): | ||
| filtered_keys = [k for k in extras_require if k != 'nebius'] | ||
| extras_require['all'] = sum( | ||
| [v for k, v in extras_require.items() if k != 'nebius'], []) | ||
| else: | ||
| extras_require['all'] = sum(extras_require.values(), []) | ||
| # Nebius needs python3.10. If python 3.9 [all] will not install nebius | ||
| clouds_for_all.remove('nebius') | ||
|
|
||
| if sys.version_info >= (3, 12): | ||
| # The version of ray we use does not work with >= 3.12, so avoid clouds | ||
| # that require ray. | ||
| clouds_for_all -= {'ibm', 'docker', 'scp'} | ||
|
||
| # vast requires setuptools==51.1.1 which will not work with python >= 3.12 | ||
| # TODO: Remove once https://github.com/vast-ai/vast-sdk/pull/6 is released | ||
| clouds_for_all.remove('vast') | ||
|
|
||
| extras_require['all'] = list( | ||
| set().union(*[extras_require[cloud] for cloud in clouds_for_all])) | ||
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
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.
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.
Starting in Python 3.12, there is a warning `.../sky/provision/docker_utils.py:333: SyntaxWarning: invalid escape sequence '&'.
This should be what's intended.