Release 2.0
This is a tracking issue for release 2.0.
I am trying to give better visibility for upcoming changes and so am trying out making a PR for a release here, pulling from the official next release branch into master. This allows for the current pending changes to be easily visible.
Please keep feature requests in their own issues
I'm also leaving this PR unlocked so people can make comments/etc. and we'll see how it goes :) If you want to make a comment on a particular change, please make the comment in the "Files changed" tab so comments are not lost during a rebase.
List of changes for release:
- [ ] Add pending change (@UlisesGascon) https://github.com/expressjs/body-parser/pull/66#pullrequestreview-2201522426
- [ ] ~Add generic body parser (@jonchurch @ctcpip TBD status)~
- [ ] ~Add
limit: nullas alias forlimit: Infinity#493~ - [ ] ~Add multipart field body parser~
- [x] Drop support for Node.js 0.8
- [x] Drop support for Node.js below 18
- [x]
req.bodyno longer always set to{}, which works better for non-object-like bodies like text - [x]
on-finishedused to detect if the request has been read; no longer need to setreq._bodyto a truthy value - [x]
urlencodedno longer defaultsextendedtotrue - [x] Update
raw-bodyto v3 https://github.com/stream-utils/raw-body/pull/87 - [x] #406
List of deprecated things removed:
- [x] Main
bodyParser()function which didurlencoded+json
Testing this release
If you want to try out this release, you can install it with the following command:
$ npm cache clean
$ npm install expressjs/body-parser#2.x
$ npm cache clean
@dougwilson isn't abstraction from parsers or whatever scheduled-ish for 2.0?
Yea, I haven't fully added everything to the checklist yet. I just wanted to make the PR so it starts to get eyes.
@dougwilson Would love to use this, have you thought about publishing to npm as 2.0.0-beta1? Thanks :+1:
Hey @LinusU ! I never published it because I didn't think there was anyone wanting to start, so without demand, I did not want to burden myself with maintaining two working release lines at once, if it wasn't necessary. I'll see about getting a alpha/beta out, though :) You can always add a branch/commit of a git repo as an npm dependency, though.
Cool. I mainly wanted the first bullet which caused a bug for me when only using the raw middleware. But I just worked around it in code since I still want to get bugfixes. Would be cool to get 2.0 out for real thought. Whats missing? Is there anything I can help with?
Hey @dougwilson! So I just found this because of the bugs I've been battling today related to #128, but I see the issue and this PR have been open for over a year despite being fixed. Since it doesn't look like this is going to happen (or is there still a chance?), is the only option to fork and release under a different name?
Hi @theganyo , you are certainly welcome to fork & release this under another module, as it is under the MIT license, but there are a few reasons why it has yet to be released:
- I had a report that the changes in here can sometimes stall out a request. I have not been able to look, but if you would like to test it out on your systems (using the instructions provided in the original post), that would be much appreciated!
- This was proposed over a year ago, but with Express 3.x still supported and relying on this module, it was not possible to release a breaking version without adding more work for myself, which is all done unpaid, and so I've been waiting for Express 3.x to go away first.
is the only option to fork and release under a different name?
You can always depend on the branch in GitHub in your package.json... https://docs.npmjs.com/files/package.json#git-urls-as-dependencies
And since Express 3.x is now "officially unsupported", I want to just make one last 1.x release here and then publish a 2.0.0 alpha for people to start testing on.
Thanks, Doug. As you might have guessed, forking and releasing isn't at top of my list of alternatives. :) I just wanted to gauge whether this was really still potentially going to be supported. Since you're looking at a new release, I'll just hack around it for now and update later. Thanks for the quick reply!