Seeweb backend: pydantic v2 alignment and review fixes - #1
Open
peterschmidt85 wants to merge 1 commit into
Open
Conversation
- Migrate configurator and backend-data models to pydantic v2 idioms - Add unallocated_resources to get_offers_by_requirements (current base signature) - Update tests to gpuhunt CatalogItem - Compose the first-boot script from base helpers instead of slicing get_shim_commands(); write the shim env file from get_shim_env() - Align server/action statuses with Seeweb's ecsapi enums (add missing "Fail") - Docs: correct control-panel section name, drop implementation-detail paragraph - Revert the /CI_TESTING.md .gitignore entry Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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.
Review fixes for dstackai#4070, targeting this fork's
masterso the main PR picks them up on merge.Changes
validate_extra_ignore,model_validate,model_dump_json) — dstack dropped the v1 shims, so__response__/parse_obj/.dict()/.json()now fail at runtime.unallocated_resourcesparameter toget_offers_by_requirements(theComputeWithFilteredOffersCachedsignature gained it; without it every offer listing raisesTypeError).CatalogItem(RawCatalogItemwas removed;provideris now required).get_setup_cloud_instance_commands+get_shim_pre_start_commands+get_shim_env) instead of slicingget_shim_commands()[:-1], and write/etc/dstack-shim.envfrom the env dict rather thanenv | grep.ecsapiSDK enums — notably adds the canonicalFailserver status, which the previous set missed (a failed server would poll to the provisioning timeout instead of failing fast).Compute(notCalculation); drop the provisioning-internals paragraph; revert the/CI_TESTING.md.gitignore entry.Verification
pytest src/tests/_internal/core/backends/seeweb src/tests/_internal/server/routers/test_backends.py— 67 passed, 36 skipped; ruff clean.cuInitin-container on both GPUs), andNoCapacityErrorfallthrough exercised against sold-out plans.🤖 Generated with Claude Code