Skip to content

Conversation

@cwangsmv
Copy link
Contributor

@cwangsmv cwangsmv commented Nov 26, 2025

Background

Currently we're using InsomniaFileSchema.parse to parse git yaml files directly. Whenever it meets malformed yaml files or yaml file that is not supported for current version, it will throw error and the application will crash.

Changes

  • Using InsomniaFileSchema.safeParser to parse yaml files instead.
  • Throw error when file.type is not recognized rather than fall back to mock server workspace by default
  • Add unit test to cover unsupported yaml file

INS-1763

@cwangsmv cwangsmv requested a review from a team November 26, 2025 03:17
@cwangsmv cwangsmv requested review from CurryYangxx, gatzjames, pavkout and yaoweiprc and removed request for a team December 9, 2025 06:41
@cwangsmv cwangsmv force-pushed the fix/using-safeParser-for-git-sync branch from 6e50887 to dc05823 Compare December 9, 2025 06:41
Copy link
Contributor

@yaoweiprc yaoweiprc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

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.

3 participants