Hack Forums
Convo Image Upload Limit - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Hack Forums Official Information (https://hackforums.net/forumdisplay.php?fid=1)
+--- Forum: Site News (https://hackforums.net/forumdisplay.php?fid=2)
+--- Thread: Convo Image Upload Limit (/showthread.php?tid=6220918)

Pages: Pages 1 2


Convo Image Upload Limit - Omniscient - Sep 14, 2022

So it appears that Convo has an issue with upload size limits. I just banged out 2 hours trying to figure it out.

Issue seems to be that when you upload a file over 1mb the socket disconnects you. I do not know why. It's seemingly unrelated to Nginx or Apache as I was able to upload a 3mb txt file just fine through MyBB.

I'm looking through all the nodejs code and I don't see where a 1mb limit does this nor can I find any evidence of a default restriction causing the problem. There is nothing in logs either.

I'm going to continue working on this but for now I have updated the convo js so that it simply provides you an error on the 1mb instead of disconnecting your socket.

The current method of uploading and displaying the images is we base64 encode them. It's actually a good way to do it for security. We don't technically store files on HF so if you uploaded a payload it's not gonna do anything.

Members can CTRL+F5 this file to get the latest version with the 1mb limit. Or just stay with the one you have and it will basically just socket disconnect you on files between 1mb and 2mb.

https://hackforums.net/jscripts/convo_223.js

Meh. I hope I can get this resolved within a reasonable time frame. The goal is to fix it so the limit is maybe 3mb so that camera images actually work to upload.

Thank you.


RE: Convo Image Upload Limit - DashPHP - Sep 14, 2022

Thanks for the update Omni.


RE: Convo Image Upload Limit - 007 - Sep 14, 2022

[mention=3707989] maybe this is what got us disconnected when sending pics from phone.


RE: Convo Image Upload Limit - Omniscient - Sep 14, 2022

Got it working for 3mb. Finally.

But I still may need to adjust the code as the way I did it isn't optimal. But at least I found out why. Looks like a limit with socket.io and their maxHttpBufferSize variable. It's default 1mb. Tuned it to 3mb but may end up lowering it to 2mb.

Thanks for being patient.


RE: Convo Image Upload Limit - Omniscient - Sep 14, 2022

Got it 100% now to my liking. So we're good now. Made for a long day though.


RE: Convo Image Upload Limit - Pikachu - Sep 15, 2022

When I'm on mobile and I browse the gallery yo upload a picture, if it takes me a while to scroll through the gallery i still get disconnected. I don't even have to choose an image, if I back out of it I'm still disconnected. Happens every time to me.


RE: Convo Image Upload Limit - Omniscient - Sep 15, 2022

(Sep 15, 2022 09:26 AM)Pikachu Wrote:  When I'm on mobile and I browse the gallery yo upload a picture, if it takes me a while to scroll through the gallery i still get disconnected. I don't even have to choose an image, if I back out of it I'm still disconnected. Happens every time to me.

What phone do you use? Android or iPhone? And is it a newer model? Doubt it's your device but need to ask. Also can anyone else confirm this? I've never had a problem going to gallery and posting.


RE: Convo Image Upload Limit - Pikachu - Sep 15, 2022

(Sep 15, 2022 09:41 AM)Omniscient Wrote:  What phone do you use?  Android or iPhone?  And is it a newer model?  Doubt it's your device but need to ask. Also can anyone else confirm this?  I've never had a problem going to gallery and posting.

I use a Galaxy s21 fe, its the newer model of the s21


RE: Convo Image Upload Limit - Omniscient - Sep 15, 2022

(Sep 15, 2022 09:47 AM)Pikachu Wrote:  I use a Galaxy s21 fe, its the newer model of the s21

So let's say you go to gallery and time it, does it timeout after 10 seconds? 20 seconds? How long before it's an issue? If you can actually time it, I might be able to see if it's a setting on our end for a timeout. It shouldn't be but if you want me to try and fix this I need to know the length of time.


RE: Convo Image Upload Limit - Pikachu - Sep 15, 2022

(Sep 15, 2022 09:58 AM)Omniscient Wrote:  So let's say you go to gallery and time it, does it timeout after 10 seconds?  20 seconds?  How long before it's an issue?  If you can actually time it, I might be able to see if it's a setting on our end for a timeout.  It shouldn't be but if you want me to try and fix this I need to know the length of time.

Probably between 30 and 45 seconds, I just tested it a few times


RE: Convo Image Upload Limit - Omniscient - Sep 15, 2022

(Sep 15, 2022 10:10 AM)Pikachu Wrote:  Probably between 30 and 45 seconds, I just tested it a few times

And if you do it within 15 seconds?


RE: Convo Image Upload Limit - Pikachu - Sep 15, 2022

(Sep 15, 2022 10:22 AM)Omniscient Wrote:  And if you do it within 15 seconds?

Within 15 seconds I have no issues so far.  But if I'm looking through my gallery trying to find a certain picture and it exceeds about 30 seconds then it disconnects


RE: Convo Image Upload Limit - Omniscient - Sep 15, 2022

(Sep 15, 2022 11:35 AM)Pikachu Wrote:  Within 15 seconds I have no issues so far.  But if I'm looking through my gallery trying to find a certain picture and it exceeds about 30 seconds then it disconnects

Hm...that's helpful. I'll try to see if there is a setting in the socket for that and try to extend it to 60 seconds.


RE: Convo Image Upload Limit - Pikachu - Sep 15, 2022

(Sep 15, 2022 11:41 AM)Omniscient Wrote:  Hm...that's helpful. I'll try to see if there is a setting in the socket for that and try to extend it to 60 seconds.

Awesome sounds good. Yeah extending that to 60 seconds will definitely help.


RE: Convo Image Upload Limit - Omniscient - Sep 15, 2022

(Sep 15, 2022 11:43 AM)Pikachu Wrote:  Awesome sounds good. Yeah extending that to 60 seconds will definitely help.

Also have you tested this on desktop? My guess is the same behavior.