AIFW-24958: connection status unspecified not handled in event model enum#106
Merged
Conversation
Signed-off-by: Volodymyr Kit <vokit@cisco.com>
shiva-guntoju-09
approved these changes
Jun 5, 2026
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.
Summary
Adds support for the API value
ConnectionStatusUnspecifiedin management connection models.This change prevents parsing failures when connection or expanded event responses include an unspecified connection status. It adds enum coverage, validates the behavior through connection and event client unit tests, and updates one management example call to match the current event conversation API signature.
Changes
ConnectionStatus.Unspecifiedenum value mapped toConnectionStatusUnspecified.get_connection()parsing connections with unspecified status.list_events()get_event()management_client_usage.pyto callget_event_conversation(first_event.event_id)without the removed/unsupportedexpanded=Trueargument.Test Plan
main.aidefense/tests/test_connection_management_client.pyaidefense/tests/test_event_management_client.pyCompatibility Notes
ConnectionStatusUnspecifiednow parse correctly.Files Modified
aidefense/management/models/connection.py- AddedConnectionStatus.Unspecified.aidefense/tests/test_connection_management_client.py- Added connection parsing test for unspecified status.aidefense/tests/test_event_management_client.py- Added expanded event parsing tests for unspecified connection status.examples/management/management_client_usage.py- Updatedget_event_conversation()example call.Total: 86 insertions(+), 1 deletion(-)