Fix: get_servers nullable field validation errors#45
Merged
Conversation
platanus-kr
pushed a commit
that referenced
this pull request
Aug 16, 2025
halucinor
pushed a commit
that referenced
this pull request
Aug 24, 2025
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.
Fix: get_servers nullable field validation errors
Overview (한글)
OpenStack MCP 서버에서
get_servers호출 시 발생하던 Pydantic 유효성 검증 오류를 수정했습니다. Server 모델의 Flavor와 Image 필드에서 nullable 값 처리가 누락되어 발생하던 문제를 해결했습니다.Key Changes (주요 변경사항)
Server.Flavor.name필드를 nullable로 변경 (str | None)Server.Image.id필드를 nullable로 변경 (str | None) 및 기본값 설정Related Issues (관련 이슈)
다음 Pydantic 유효성 검증 오류 해결:
Additional context (추가 정보)
OpenStack API에서 서버 정보를 조회할 때, 특정 상황에서 flavor의
original_name이나 image의id값이None이거나 누락될 수 있습니다. 이는 서버가 삭제된 이미지나 flavor를 참조하거나, 임시적인 상태에 있을 때 발생할 수 있는 정상적인 케이스입니다. 이러한 경우를 안전하게 처리하기 위해 필드들을 nullable로 변경했습니다.Overview
Fixed Pydantic validation errors occurring when calling
get_serversin the OpenStack MCP server. Resolved issues with missing nullable value handling in Server model's Flavor and Image fields.Key Changes
Server.Flavor.namefield to nullable (str | None)Server.Image.idfield to nullable (str | None) with default valueRelated Issues
Resolves the following Pydantic validation errors:
Additional context
When querying server information from the OpenStack API, the
original_nameof a flavor or theidof an image can beNoneor missing in certain situations. This can occur when a server references a deleted image or flavor, or when it's in a transitional state. These are normal cases that should be handled gracefully, which is why the fields have been made nullable.Testing
get_serversno longer throws validation errors