body-parser icon indicating copy to clipboard operation
body-parser copied to clipboard

Release 2.0

Open dougwilson opened this issue 11 years ago • 13 comments

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: null as alias for limit: 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.body no longer always set to {}, which works better for non-object-like bodies like text
  • [x] on-finished used to detect if the request has been read; no longer need to set req._body to a truthy value
  • [x] urlencoded no longer defaults extended to true
  • [x] Update raw-body to v3 https://github.com/stream-utils/raw-body/pull/87
  • [x] #406

List of deprecated things removed:

  • [x] Main bodyParser() function which did urlencoded + 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 avatar Oct 30 '14 01:10 dougwilson

@dougwilson isn't abstraction from parsers or whatever scheduled-ish for 2.0?

Fishrock123 avatar Oct 30 '14 01:10 Fishrock123

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 avatar Oct 30 '14 01:10 dougwilson

@dougwilson Would love to use this, have you thought about publishing to npm as 2.0.0-beta1? Thanks :+1:

LinusU avatar Aug 03 '15 09:08 LinusU

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.

dougwilson avatar Aug 28 '15 00:08 dougwilson

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?

LinusU avatar Aug 28 '15 09:08 LinusU

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?

theganyo avatar Nov 06 '15 00:11 theganyo

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:

  1. 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!
  2. 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

dougwilson avatar Nov 06 '15 00:11 dougwilson

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.

dougwilson avatar Nov 06 '15 00:11 dougwilson

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!

theganyo avatar Nov 06 '15 00:11 theganyo