mirror of
https://github.com/hoppscotch/hoppscotch.git
synced 2026-04-26 01:06:00 +03:00
[PR #5127] [MERGED] feat: add support for version bounded parsing and migration #5070
Labels
No labels
CodeDay
a11y
browser limited
bug
bug fix
cli
core
critical
design
desktop
discussion
docker
documentation
duplicate
enterprise
feature
feature
fosshack
future
good first issue
hacktoberfest
help wanted
i18n
invalid
major
minor
need information
need testing
not applicable to hoppscotch
not reproducible
pull-request
question
refactor
resolved
sandbox
self-host
spam
stale
testmu
wip
wont fix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/hoppscotch#5070
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/hoppscotch/hoppscotch/pull/5127
Author: @jamesgeorge007
Created: 6/4/2025
Status: ✅ Merged
Merged: 6/5/2025
Merged by: @jamesgeorge007
Base:
main← Head:feat/versioned-entity-enhancements📝 Commits (1)
381de9ffeat: add support for version bounded parsing and migration📊 Changes
20 files changed (+446 additions, -102 deletions)
View changed files
📝
packages/hoppscotch-cli/package.json(+2 -2)📝
packages/hoppscotch-cli/src/__tests__/e2e/commands/test.spec.ts(+18 -0)➕
packages/hoppscotch-cli/src/__tests__/e2e/fixtures/collections/invalid-mixed-versions-coll.json(+48 -0)➕
packages/hoppscotch-cli/src/__tests__/e2e/fixtures/collections/valid-mixed-versions-coll.json(+90 -0)📝
packages/hoppscotch-cli/src/__tests__/unit/fixtures/workspace-access.mock.ts(+76 -2)📝
packages/hoppscotch-cli/src/__tests__/unit/workspace-access.spec.ts(+24 -6)📝
packages/hoppscotch-cli/src/utils/workspace-access.ts(+48 -14)📝
packages/hoppscotch-common/package.json(+1 -1)📝
packages/hoppscotch-data/package.json(+2 -2)📝
packages/hoppscotch-data/src/collection/v/1.ts(+5 -5)📝
packages/hoppscotch-data/src/collection/v/2.ts(+14 -6)📝
packages/hoppscotch-data/src/collection/v/3.ts(+14 -6)📝
packages/hoppscotch-data/src/collection/v/4.ts(+17 -7)📝
packages/hoppscotch-data/src/collection/v/5.ts(+17 -7)📝
packages/hoppscotch-data/src/collection/v/6.ts(+17 -7)📝
packages/hoppscotch-data/src/collection/v/7.ts(+17 -7)📝
packages/hoppscotch-data/src/collection/v/8.ts(+18 -8)📝
packages/hoppscotch-selfhost-desktop/package.json(+2 -2)📝
packages/hoppscotch-selfhost-web/package.json(+1 -1)📝
pnpm-lock.yaml(+15 -19)📄 Description
This PR introduces enhancements to the CLI Collection runner, including:
Support for mixed versions: Allows child collections to be based on different schema versions than the parent collection.Improved compatibility with legacy ID (collection/environment) formats: Enhances support for incoming data using ID formats from older versions.Closes #5119, HFE-893.
What's changed
HoppCollectionversioned entity adding the ability to support children conforming to different version ranges. Leverages theentityRefUptoVersion()function addition onverzodend specifying valid version range for child collections, ref.verzodacross packages.zodunderselfhost-desktop.Notes to reviewers
Try running a collection via the CLI where child collection entries are based on a different version than the parent collection. For instance, the collection here.
P.S: This is intended to be merged straightaway to
mainto issue a patch release for the CLI and the remaining changes scoped underhoppscotch-common,hoppscotch-selfhost-web, etc will be released separately alongside the usual patch release since they don't have an effect as such due to gracefully handling imports failing schema parsing.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.