mirror of
https://github.com/hoppscotch/hoppscotch.git
synced 2026-04-26 01:06:00 +03:00
[PR #3293] [MERGED] fix: fix issues with codegen #4327
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#4327
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/3293
Author: @amk-dev
Created: 8/25/2023
Status: ✅ Merged
Merged: 8/28/2023
Merged by: @AndrewBastin
Base:
release/2023.8.0← Head:fix/codegen-errors📝 Commits (2)
83aab35fix: fix issues with httpsnippet upgrade2ce81e0chore: fix HttpSnippet import📊 Changes
5 files changed (+274 additions, -184 deletions)
View changed files
📝
package.json(+9 -0)📝
packages/hoppscotch-common/package.json(+2 -1)📝
packages/hoppscotch-common/src/helpers/new-codegen/har.ts(+9 -2)📝
packages/hoppscotch-common/src/helpers/new-codegen/index.ts(+1 -1)📝
pnpm-lock.yaml(+253 -180)📄 Description
Closes HFE-150
Before
Generating code for requests were breaking. the package we were using
httpsnippetwas depending onajv@6, but they didnt have it on their peerDependencies, it was picking up ajv@8 which are added by some other packages, which breakshttpsnippet.After
Fixed it for now with pnpm's
pnpm.packageExtensionswhich patches httpsnippets package.json to include the ajv@6 in peerDeps.After the fix, codegeneration worked normally except for when there are no body. we set
HAR.Request.postDataas optional. buthttpsnippetwas considering it mandatory. to fix this, we usex-unknownas thepostData.mimeTypewhen the contentType is unknown.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.