Ideas for Bun v1.2 #16290
fel1x-developer
started this conversation in
Ideas
Ideas for Bun v1.2
#16290
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Dear Bun core members,
From the latest release note, I read that
So the release of Bun v1.2 is imminent, happening in two weeks.
I have suggestions for the v1.2 release, which can significantly improve the user/developer experience in using Bun.
The new lockfile
I suggest removing
--save-text-lockfile
option forbun install
and introduce--save-binary-lockfile
for bun.lockb compatibility.bun.lockb
files in oven-sh/bun repo should be replaced withbun.lock
(text lockfile) before the 1.2.0 release.Currently, there are 41
bun.lockb
files (including for tests).Semantic versioning for Bun
I have always been wondering why Bun's versioning policy is a bit different from the de facto semantic versioning (semver) that is widely used in node/npm ecosystem.
NPM says:
In semantic versioning, a patch release is for "Backward compatible bug fixes" while minor release is for "Backward compatible new features" and major release is for "Changes that break backward compatibility".
The 43 patch releases in Bun since v1.1.0 introduced many new features and bug fixes while maintaining backward compatibility. According to semantic versioning, most of the releases should have been minor releases. For example, Bun 1.1.39 should have been a minor release while releases like 1.1.42 can remain as a minor release.
Bun v1.2.0 will have some breaking changes, such as making text lockfile default option for
bun install
. (more breaking changes can be found here I think the new version of Bun should be released as v2.0.0, not v1.2.0, and follow semantic versioning policy for future releases.This has two advantages that benefit end users.
Users can expect what the update is about. For example, they will know it's a bug fix if there is a new release 2.0.1 from 2.0.0. They can expect a new feature from minor release like 2.1.0 from 2.0.0. This helps users save time from reading the whole release note from top to bottom before upgrading bun since the semantic versioning hints them what the release is about.
Semantic versioning is the de facto standard for NPM ecosystem, and there are packages that install bun from
package.json
. By convention, they expect bug fixes only from"bun": "~2.0.0"
, but under the current Bun versioning policy, this can introduce new features which the end users do not expect. We should follow NPM's recommendation, again:I found that open source projects like Svelte make releases while strictly sticking with the semantic versioning policy.
Open sourcing the website
Many open source projects make the source code for their website public. (e.g. nodejs.org, svelte.dev, hono.dev)
Should Bun open source its website as well?
Beta Was this translation helpful? Give feedback.
All reactions