[web2py] upload bug in filename

2010-06-14 Thread Swell
Hi , I tried to send a file with a form containing a upload field( actually it is a SQLFORM). When i try to add a new record with the administrative db interface , it breaks if the filename if very long ( not sure where it comes from ). Any idea? Thx

[web2py] Re: upload bug in filename

2010-06-15 Thread Swell
ename? > > Isn't there like a 255 char limit to filenames? > -- > Thadeus > > > > On Mon, Jun 14, 2010 at 4:58 PM, Swell wrote: > > Hi , > >  I tried to send a file with a form containing a upload > > field( actually it is a SQLFORM). When i try to add

[web2py] Re: upload bug in filename

2010-06-17 Thread Swell
There is nothing suspicious here about the filename ( it was an example here, but it has the same effect with a file containing the description oof the paper + all the authors ). I am almost sure that it is related to size of the path + filename that is not correctly handled . But i can't spot wher

[web2py] Re: upload bug in filename

2010-06-17 Thread Swell
Tymciurak wrote: > On Jun 17, 4:59 pm, Swell wrote: > > > There is nothing suspicious here about the filename ( it was an > > example here, but it has the same effect with a file containing the > > description oof the paper + all the authors ). I am almost sure that > >

[web2py] Re: upload bug in filename

2010-06-23 Thread Swell
Ok I will post some code here to show as much as possible here is the db definition: db.define_table('papers', Field('title','string'), Field('author','string'), Field('file','upload'), ) then if i try to use the database administration tool available in Models section and try to insert

[web2py] Re: upload bug in filename

2010-06-25 Thread Swell
Thx you for your help, i am thinking now that it is maybe not the filename itself that is wrong but maybe filepathname. I mean that it is the concat of the basename and filename is maybe too long . i am going to look at this (by changing the web2py src tree to c:\ so that a shorter basename is goin

[web2py] Re: upload bug in filename

2010-06-25 Thread Swell
Ok i have been able to reproduce the bug , it works perfectly if the web2py tree is in c:\ it doesnot if it is copied on the desktop(C:\Users\M\Desktop\web2py) so it seems that it is related the filenamepath(basename+filename)

[web2py] Re: upload bug in filename

2010-06-26 Thread Swell
Yes i am using web2py 1.79.2 on windows 7 64b Can someone try to save the web2py files in a very long directory name ( something like 200 characters ) and use the kind of filename i provided ( long ) and see what is happening on mac/linux? I am doing local tests only , it means that the file are o

[web2py] Re: upload bug in filename

2010-07-02 Thread Swell
Hi I may hae found something if i look at line 2688 in gluon/sql.py i can see in the function store: newfilename = newfilename[:200] + '.' + extension but so far so good it doesn t break anything to truncate the filename. later in the function ( line 2699) i see pathfilename = os.path.join(path,

[web2py] Re: upload bug in filename

2010-07-03 Thread Swell
ok i hae done that and it complains about IOError: [Errno 2] No such file or directory: 'a aa