Conversation
Owner
alez007
commented
Apr 30, 2026
- Created a new package modelship/deploy.
- Moved the deployment-related logic from mship_deploy.py into smaller, focused modules inside the new package:
- modelship/deploy/config.py: Handles loading and parsing the config and resolving plugin wheels.
- modelship/deploy/serve_utils.py: Centralises Ray and Serve operations (e.g. connect_ray, start_serve, cleanup routines).
- modelship/deploy/strategy.py: Contains the actual deploy plan computations (compute_deploy_plan) and the main deployment loop (run_deploy_loop).
- Relocated the newly created actor_options.py into this package as well (modelship/deploy/actor_options.py).
added 3 commits
April 30, 2026 20:05
Extract actor options and caching logic from mship_deploy.py into modelship/actor_options.py. Extract CLI parsing arguments logic into modelship/utils/cli.py. Rename start.py to mship_deploy.py and update associated tests and references.
Moves config, strategy, and utilities for the Ray serve lifecycle out of mship_deploy.py into a cohesive package: - modelship/deploy/config.py - modelship/deploy/serve_utils.py - modelship/deploy/strategy.py - modelship/deploy/actor_options.py Updates mship_deploy.py and test files to reflect these imports.
There was a problem hiding this comment.
Code Review
This pull request refactors the deployment logic by replacing the monolithic start.py with a new entry point, mship_deploy.py, and modularizing its functionality into the modelship/deploy/ directory. The changes include updating documentation, Docker configurations, and tests to reflect the new structure. A critical issue was identified in modelship/deploy/serve_utils.py where direct access to environment variables causes a KeyError during default startup. Additionally, the use of signal.pause() in the main entry point limits cross-platform compatibility.
Only access RAY_CLUSTER_ADDRESS and RAY_REDIS_PORT from os.environ when MSHIP_USE_EXISTING_RAY_CLUSTER is set to 'true'. This prevents a KeyError on startup when running in the default 'auto' cluster mode without these variables defined.
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.