Skip to content

refactor(common, spectral-validator): introduce jentic-openapi-common package with subprocess utility#3

Merged
frantuma merged 1 commit intomainfrom
feat/common-shared-code
Sep 17, 2025
Merged

refactor(common, spectral-validator): introduce jentic-openapi-common package with subprocess utility#3
frantuma merged 1 commit intomainfrom
feat/common-shared-code

Conversation

@frantuma
Copy link
Collaborator

@frantuma frantuma commented Sep 17, 2025

Add new jentic-openapi-common package containing shared utilities for OpenAPI-related operations:

  • Implement run_checked subprocess utility with enhanced error handling.
  • Add SubprocessExecutionError to handle non-zero exit codes.
  • Include type-checking support with py.typed.
  • Update workspace and CI configurations to include jentic-openapi-common.
  • Replace direct subprocess.run calls with run_checked in spectral_validator.py for improved error handling and result encapsulation.

This package provides reusable functionality for subprocess management, aiding other OpenAPI tools in the monorepo.

@frantuma frantuma requested a review from char0n September 17, 2025 15:02
Copy link
Member

@char0n char0n left a comment

Choose a reason for hiding this comment

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

I usually try to avoid common or lib packages, but I understand the motivation. Could we rename it to commons though?

Left one review comment directly in code as well.

@frantuma frantuma force-pushed the feat/common-shared-code branch from 4f5e98e to 9a6cd35 Compare September 17, 2025 16:10
@frantuma frantuma changed the title feat(common): introduce jentic-openapi-common package with subprocess utility refactor(common, spectral-validator): introduce jentic-openapi-common package with subprocess utility Sep 17, 2025
…n` package with subprocess utility

Add new `jentic-openapi-common` package containing shared utilities for OpenAPI-related operations:

- Implement `run_checked` subprocess utility with enhanced error handling.
- Add `SubprocessExecutionError` to handle non-zero exit codes.
- Include type-checking support with `py.typed`.
- Update workspace and CI configurations to include `jentic-openapi-common`.
- Replace direct `subprocess.run` calls with `run_checked` in `spectral_validator.py` for improved error handling and result encapsulation.

This package provides reusable functionality for subprocess management, aiding other OpenAPI tools in the monorepo.
@frantuma frantuma force-pushed the feat/common-shared-code branch from 9a6cd35 to 7065bf6 Compare September 17, 2025 16:29
@frantuma
Copy link
Collaborator Author

@char0n (sorry did a refactor without remembering I asked a review..)

@frantuma frantuma requested a review from char0n September 17, 2025 16:41
@frantuma frantuma merged commit d619635 into main Sep 17, 2025
12 checks passed
@frantuma frantuma deleted the feat/common-shared-code branch September 17, 2025 18:30
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