Skip to content

Conversation

sushobhit-lt
Copy link
Collaborator

This pull request introduces several improvements and bug fixes related to snapshot processing, status tracking, and build context management in the SmartUI CLI. The changes primarily focus on making the context-to-snapshot mapping more robust by switching status tracking from numeric codes to string-based identifiers, improving reliability in snapshot status polling, and enhancing API request payloads with additional metadata.

Key changes include:

Context and Snapshot Status Management:

  • The contextToSnapshotMap now uses string values (such as build IDs or status codes as strings) instead of numbers to track the status of each context, improving clarity and consistency in status handling throughout the codebase. [1] [2] [3] [4]
  • The snapshot status polling logic in server.ts is updated to handle string statuses, includes a timeout mechanism, and now retrieves the correct build ID from the map for external status checks.

Snapshot Processing and API Enhancements:

  • The processSnapshotCaps and uploadSnapshotForCaps methods in httpClient.ts now accept variantCount and sync parameters, and these values are included in the API request payloads, providing more detailed context for snapshot processing. [1] [2] [3]
  • When using Kafka Flow with capabilities, the snapshot UUID is now set to the context ID if available, ensuring better traceability between contexts and snapshots.

API Request Improvements:

  • The getSnapshotStatus method now requires an explicit buildId parameter, rather than relying on ctx.build.id, making the method more flexible and accurate in multi-build scenarios.

Miscellaneous:

  • The package version is bumped to 4.1.37-beta.0.

These changes collectively improve the reliability and traceability of snapshot handling, especially in parallel and distributed test execution environments.

@sushobhit-lt sushobhit-lt merged commit 79c337e into prod Oct 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants