Error on web client sao

56 views
Skip to first unread message

Diego Abad

unread,
Dec 4, 2015, 1:05:04 PM12/4/15
to tryton-dev
Hello,

I am testing sao client with an application.  One form of my app have a binary field with image widget.
When I want to upload a file biggest than 100Kb and try to save the registry, sao show "processing..." message indefinitely.
When I upload a file smallest than 100Kb this work.

I am using version 3.8 on Archlinux.

Grettings...

Cédric Krier

unread,
Dec 4, 2015, 5:05:03 PM12/4/15
to tryton-dev
I think you should report an bug.
I suspect a limitation on the size for Blob or createObjectURL creation.
Please check the browser log if there is no error message and include it
on the bug report (usually when "processing..." stays is because an
exception was raised at an unexpected place).

--
Cédric Krier - B2CK SPRL
Email/Jabber: cedric...@b2ck.com
Tel: +32 472 54 46 59
Website: http://www.b2ck.com/

Diego Abad

unread,
Dec 13, 2015, 3:49:46 AM12/13/15
to tryton-dev
About this topic...

BIG_IMAGE_SIZE value is set to  Math.pow(10, 6) -> 1MB

however
apparently the error is that the comparison
 if (value > Sao.common.BIG_IMAGE_SIZE) is true

although my image size is 482kB.

I test changing BIG_IMAGE_SIZE to
Math.pow(10, 7) and works.
But I when I return BIG_IMAGE_SIZE to original value
Math.pow(10, 6) now also works...

Cédric Krier

unread,
Dec 13, 2015, 4:35:03 AM12/13/15
to tryton-dev
On 2015-12-12 01:23, Diego Abad wrote:
> About this topic...
>
> BIG_IMAGE_SIZE value is set to Math.pow(10, 6) -> 1MB
>
> however apparently the error is that the comparison
> if (value > Sao.common.BIG_IMAGE_SIZE) is true
> although my image size is 482kB.

Did you get this by using a debugger?
What was the value of 'value'?

> I test changing BIG_IMAGE_SIZE to Math.pow(10, 7) and works.
> But I when I return BIG_IMAGE_SIZE to original value Math.pow(10, 6) now
> also works...

This is very strange. Unreproducible bugs are most of the time
impossible to fix.

PS: Please don't top-post on this mailing list, see
http://groups.tryton.org/netiquette

Diego Abad

unread,
Dec 13, 2015, 7:45:04 AM12/13/15
to tryton-dev
To reproduce the error, I am using:
Trytond 3.8.0
Sao from hg -> commit: 9635.  The last commit at time
Chromium 47.0.2526.80

I debug the code and see that the problem is on call to function String.fromCharCode.apply(null, value) on tryton-sao.js:676  inside  Sao.rpc.prepareObject.
I found this info concerning:
https://github.com/michael/github/issues/137
https://github.com/mathiasbynens/String.fromCodePoint/issues/1

I can confirm that Firefox dont produce this error.

Regards.

Cédric Krier

unread,
Dec 13, 2015, 7:55:03 AM12/13/15
to tryton-dev
Please fill an bug on https://bugs.tryton.org/ included the traceback.
Reply all
Reply to author
Forward
0 new messages