-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Release between v0.3.9 and v0.3.15 broke semver #1073
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Thank you for reporting this but since marked is still in beta (0.x) semver allows any non-breaking changes to update the last digit instead of the middle one. |
Fair enough. I missed that it's still in beta. Doesn't say it in the readme. To make that clear maybe call it Food for thought? |
You're of course quite right though: |
Just want to add more detail to make sure folks who stumble upon this later. Semantic versioning is more about APIs not outputs. This question and point falls under semantic versioning 3 and 4.
Because the package contents of previous versions was not changed, we are still abiding by semantic versioning 3 and consumers can take the option of using the previous version. To the best of my knowledge the APIs have not changed much, if at all, yet; therefore, still okay under the major zero concepts with the added benefit of not changing the APIs. There are three milestones we are working toward, which will indicate more drastic changes: https://github.com/markedjs/marked/milestones
Because development on the library stalled a bit, and for a long period of time, I know many of our users may have felt it was stable; however, it's more like it just didn't change while still having some issues. We have also generated the RELEASE document, which describes how are extending semantic versioning for our context and purposes. Thank you again for submitting this issue. |
@dominikwilkowski thanks for writing, we greatly appreciate your feedback 👍
I'm shifting toward thinking that the email autolinking should have deserved a minor bump, since it can change the output significantly (as happened to you), but since we're in 0.x that would be too much. ProposalConsidering the points above, my proposal to @joshbruce and @UziTech is this: we should accelerate the bump to 1.0, declaring it the new "no defects" release instead of the 0.4. Until that, we bump the minor version for every "breaking" change we introduce (like the case with email autolinks). The 1.0 will be API compatible with 0.3, but it will be safe, almost 100% compliant with commonmark and gfm. No extensions or frills. I don't know if this would be 100% compliant with semantic versioning, as I think the 1.0 should be the stable public API, but I think we're free to decide the API won't change in 1.0. Pros:
Cons:
|
Thank you all for engaging with me on this. The I think moving to a new major We shouldn't be afraid of breaking changes when we develop and maintain a software and semver helps us with that. Staying on an unstable On both of your points that the API is still the same therefor it's not a breaking change, surely when you return something different you break things, especially for an API that is solely concerned about how to format a string. But I take your point and don't want to run into semantic discussions. The best point I think here was made by @Feder1co5oave
That makes complete sense especially in context of the package still being developed. I was only caught in this issue because I wrongly assumed marked was stable as I've been using it for years. Bumping to |
Uh oh!
There was an error while loading. Please reload this page.
Hi there
First of all thank you for the hard work on marked. I do appreciate this package a lot and want to acknowledge that.
I noticed that between v0.3.9 and v0.3.15 (I assume v0.3.12 as it mentions
Improved links
) marked started parsing email links and wrapping them into links. A welcome change and it seems to work great but it certainly broke semver.A change like that is a major change as the same input yields different output in my personal opinion. But even if you disagree on major it is at the very least a minor change as it adds a feature and most certainly not a patch.
I found it as it broke our integration tests in older node versions (we test several) which don't support the
package.lock
file and installed a newer version of marked that our fixtures hadn't accounted for. Not an easy thing to track down :)Anyway hope this helps as a hint.
The text was updated successfully, but these errors were encountered: