Comments (5)
Perhaps the request is using different headers for files. Beyond that, there's not much I can suggest. You'd have to ask on the nuxt project issue tracker or wherever.
from busboy.
Yea it was some different implementation on frontend thx, is there a way to check if the busboy found a error on receveing the file? Like a error listener event? Or I would have to send the size of file on body of the request and compare with size of file written after some time? Im saying after some time , because i tried to stop a request in the middle and didnt trigger the finish event listener.
from busboy.
There would be no error unless you closed the busboy instance early for example. busboy
does not inspect the data or anything like that.
If you want to handle either case, whether the form parsing was successful or not, you should be listening for the 'close'
event instead. 'finish'
is only emitted when the entire form was parsed successfully.
from busboy.
But like if the latency or there is some package loss in the middle of uploading the close event would catch that moment?
from busboy.
Measuring latency is outside of the scope of this module. Packet loss is only a thing if you're using an unreliable transport, which is unlikely, even with something like HTTP/3.
A 'close'
event will be emitted if the form data is malformed, including if you busboy.end()
early. It will also be emitted if the form data was parsed completely and successfully. Use it when you want to do something whether parsing was successful or not. Use 'finish'
only if you want to do something when the parsing was successful. Use 'error'
if you want to detect when there is an error, this will then be followed by the 'close'
event.
These events follow that of typical node.js streams.
from busboy.
Related Issues (20)
- node:http 302 redirect does not work with large file stream
- [QUESTION] Busboy and Expressjs - response not sent back to the client if next(new Error(...)) is called inside "file" event HOT 1
- Upload file stream directly to S3. Unknown content-length HOT 1
- multipart/form-data windows-1251 HOT 4
- Content-Transfer-Encoding for POST request on multipart message not working HOT 2
- ERR_CONNECTION_ABORTED with long file uploads HOT 6
- licenses in package.json is deprecated HOT 2
- Bug on UTF-8 filenames HOT 2
- Problem on utf8 filename HOT 5
- Missing Content-Type HOT 7
- [email protected] SyntaxError: Unexpected token { HOT 1
- Busboy does not recognize `image/jpeg` without `filename` as files HOT 1
- Extracting Filename when Empty String fails
- need to get raw headers HOT 1
- busboy seems to read ahead too fast for many small (< 16KiB) files HOT 5
- Events order when parsing file HOT 6
- Typings for field name HOT 1
- Unexpected end of form HOT 2
- File size unavalaible HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from busboy.