node-formidable / formidable

The most used, flexible, fast and streaming parser for multipart form data. Supports uploading to serverless environments, AWS S3, Azure, GCP or the filesystem. Used in production.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Maintainer Wanted

felixge opened this issue · comments

I haven't maintained this module in a while*, and PRs are piling up.

If anybody is interested in helping out, I'm happy to give commit bits + npm package access.

To get access, please try to write 1-2 sentences that give me a reasonable hope you're not looking to put malicious code into the package and also mention your npm account name.

* For those curious about the "why?", I'm working with Go these days haven't been using node.js for over 3 years now.

@pornel sounds good. What's your NPM account? I'll give you access :). Thanks!

I'm kornel on npm

@pornel thanks, added you on GH and NPM :).

@ChALkeR done.

I also can help when have time. I have Koajs package koa-better-body that uses formidable. It's about 3 years old and many users use it, and using it exactly because formidable.

I'm all-lowercased tunnckocore at npm.

Hi, @felixge

I'm happy to help as well. I have decent experience in creating and maintaining libraries, as well as packaging and releasing. @pornel, maybe you want someone to spar with?

Sure, the more the merrier.

@tunnckoCore added you on gh and npm.

@badeball added you only on gh since you didn't provide your npm handle.

@ all: Thank you so much for offering your help. I'll leave it up to you if you just want to merge good PRs, or add new features. A lot of people depend on this library, so big API changes are probably undesirable at this point. Anyway, I'll mostly stay out of it, unless you need my help to break a tie on a discussion or similar.

@felixge cool, thanks!

so big API changes are probably undesirable at this point.

Maybe yea. First we should try to clear the most issues.

We should add some more benchmarks against the other parsers like dicer and busboy, because I'm curious if formidable is still faster.

We should add some more benchmarks against the other parsers like dicer and busboy, because I'm curious if formidable is still faster.

I would expect newer libraries to be faster. I mean I wrote most of the parser 6 years ago, and a lot of things have changed in Node/v8 since then. There was also a lot of time to just improve on my initial ideas :).

Anyway, it would be interesting to see where things are at, but I'd be surprised if formidable wasn't "fast enough" anymore. If it can still process data faster than what your network interface on your server is rated for ... the code is probably fast enough :)

Yea exactly. In any way it is always good to have some comparison to know where we are. :)

@tunnckoCore - I would also like to help with this project :)

Very important things should be done first. Sadly I don't have the time, but veryt hanks for that @felixge added me. I always trying to comment and help in new issues, but sadly I can't commit new things and fixes. I partially believe that this project deserve to be rewritten to be more accurate.

@blueelvis It woul dbe great if you can help with the issues and the commented on #414 and #415, because I'm very tired about the whole community and I'm in pause (for relax) currently and I'm not doing anything last few weeks or so (just rage quit).

I am Interested As I need this module so much in my file Storage System and I am using it now on it streamupbox, and is my NPM name too. thank you.

@richard457 I can't find you on npm?

$ npm owner add richard457 formidable
npm ERR! owner mutate Error getting user data for richard457
npm ERR! code E404
npm ERR! 404 Registry returned 404 for GET on https://registry.npmjs.org/-/user/org.couchdb.user:richard457

npm ERR! A complete log of this run can be found in:

@kornelski @felixge What's the status of this? I am confused a bit, given d5ccbc4#r21119456.
Who is the primary maintainer of this package atm?

I guess I am? But I don't have time to maintain this properly.

commented

A company I work for uses this in production I'm rwky on npm we'd be happy to help out.

@kornelski Thanks for the clarification! =)

Has anyone actually looked through all of the outstanding PRs? For example, #267 is more than 4 years old and waiting on feedback from the original author about the appropriateness of adding the functionality to the library. The newest one in the queue is from May 2017, so just declaring bankruptcy (closing all PRs and asking users to test against the current version) might be appropriate.

@reviewher yes, I reviewed them much of them and thought for the same thing. Probably most of them are not related anymore.

Hi, I doesn't want this package to fall so I will gladly helps you to maintain this project alive!
My npm account: quantumsheep

commented

Hi. We use it (heavily) in few of our projects, and I myself have built a lot of code on top of it.
It's a pity to see it not being maintained lately, as we want to reuse our existing code-base in a new long-term enterprise project. And the code-base was built on top of it, thus we need to maintain it.

Would be glad to help to keep it alive.

NPM account: https://www.npmjs.com/~xargs

@quantumsheep @xarguments added both of you on GH / NPM. Thanks for helping!

@felixge would mind add few Github bots to the repo?
Or perhaps moving the repo to org (sounds like a better way to go for the future)?

Dear @felixge,

would you mind adding your repo on maintainerswanted.com? It's open source 🌟 https://github.com/flxwu/maintainerswanted.com and will be launched 🚀 in the next few days.

Thank you! 🙏

Best regards,
Felix

Yo @felixge can help up us a bit with moving the project to an organization?

I've just created it @node-formidable and I sent invites to most from here and to Felix.

@tunnckoCore sorry I missed your message about adding bots, I can help with that, just let me know what you need.

About transferring to an org: I'd be okay with that, but maybe you can share some more info on that? As far as I can tell @kornelski has been the most active on this repo lately, how does he feel about the org?

Orgs are more flexible in any way. It would be easier if we want to add some other contribs in the future, or adding new apps/bots to the repo, or separating some parts to other repos.

Yea, @kornelski is doing the most. I really want to update the DX and the docs.

I'm fine with an org. I'm spread thin with many projects, so whatever helps others to collaborate on this project is good.

@felixge I use this in production - would love to contribute. My npm account: amit-a

@felixge +1 on the move to org

@Amit-A, I can add you to npm tomorrow.

but anyway, I really want an org, it would do the things so much easier, at least to me.

@tunnckoCore add me as well, I'd like to contribute back to this project.

my npm account: uberthoth

@tunnckoCore I just transfered the repo to the org. Let me know if you need anything else. Sorry it took so long.

@felixge great! :) No problem, we are all busy these days, haha.

are you still looking for help? I can help triage issues and PR's as well as do some small PR myself.

@GrosSacASac sure! Unfortunately, I've not done anything in the last months, but I'm watching the repo and can review PRs and discuss things.

You can start and I can add you to NPM later.

@GrosSacASac, @xargs @quantumsheep sent you invitation for joining the org.

I accepted, but I am still unable to add labels to existing issues, and close issues :(

@GrosSacASac look now. :) I think it should be working.

My name is Corey aka Hawaiideveloper. I would like to learn and contribute to this project. I like how the library works when extrapolating.

https://www.npmjs.com/~hawaiideveloper

Contributions are welcome, I can add you later to the GitHub, npm is a bit stricter thing :)

Code is a lot cleaner and better than before (and can be a lot better), so I hope it's easy to understand and navigate.

Everything is in the issues and the comments, even with some v3 ideas.
I think #594 is easy start.

If someone has npm access, please help resolve #718 (comment)

npm is also needed to publish v1.2.3 (7e07387)

@MaxFichtelmann what's v1.2.3? Just that package.json change? Well, yea possibly when i published 1.2.2 i forgot to bump to version in package.json or what? hm.

If I am correct 1.2.3 has a fix (2021) on top of 1.2.2 but was not published to npm

Hm. Okay clear. I'll try.

the change was a fix for #433
some minor changes were needed to make the tests/travis work again/current node versions

details: v1.2.1...v1.2.3

I don't even know how to test if form.pause() and resume work. We have 2 issues around this, and don't know where to start.

commented

I'm a maintainer on the widely-used 'winston' logger (w-b-t on npm; 2FA required for that b/c it's a top-100 package) and while I can't promise any active maintenance here, I might be able to chip in on occasion (example here).

@wbt great, it's always better to have more hands and eyes. Can add you this next few days. Many things are commented and have opened issues for tracking.

hello, it's my first time on open source project, I'm curious how parsing multi-part forms work
I started my search by looking for the request interface with contenttype="multi-part/form" and I started getting results
also I tried to read through "src/Formidable.js", I was wondering can I migrate "@types/formidable" inside the project to make my mission easier
any resources to help me understand the parsing process would be appreciated
btw I used formidable myself in a couple of projects

@nagy-nabil welcome to open source! 👋

Formidable is a very old project (11 years), and its codebase might be a bit unintuitive. There are parts that sit there because of legacy reasons.

To understand the flow and look on a bit more modern base you can check out formidable-mini that I created to play around a while ago, around the same parser. But the whole thing is significantly more small because there are many things that got into the JS/nodejs core like File and FormData. The even funnier thing is that in Nodejs v19.2+ (and in the future v20 LTS) there will be NO need for any package - just 15 lines of code around native things.

For example:

// example request handler (e.g. express middleware, or serverless)
function handler(req, res) {
  // getting/"parsing" file uploads and fields in v19.2+
  const resp = new Response(req, { headers: req.headers });
  const form = await resp.formData();

  console.log([...form.entries()]);
}

This magic works, because the competitor package busbuy got into Nodejs Core. There was discussion to be formidable or busboy and they picked Busboy because it was bumped to v1 this year and it's probably a bit faster nowadays but that can change soon.

Btw, Formidable's parser is used in node-fetch too. It was copy pasted without any note or attribution anywhere. And I copy pasted the modernized variant into formidable-mini too. I tried some benchmarks there too, and from what I'm seeing, it's on par with the latest busboy that got into the Node Core.

The parser itself... it's tricky but kind of easy to follow and understand (it's the least touched thing over the years), if you are into parsing in general tho, it's not my specialty.. haha. I think to write a new parser from scratch (for learning purposes) one day based on what I learned over the years here.

Soon I'll buy a domain, create a website and write a long article around Formidable its past, present and future - the whole state of multipart parsing ("A letter to the stakeholders", haha). Because as you can see, its state and existence is... For 11 years, it's everywhere, in every 9 of 10 articles for nodejs multipart parsing and file uploads, even in Node's official website guide about file uploads. And it's STILL the most downloaded, 2x more than Busboy in fact - https://twitter.com/3a1fcBx0/status/1535663399291564047.