Error in 'admin' application

15 views
Skip to first unread message

michal niklas

unread,
Oct 30, 2008, 7:05:42 PM10/30/08
to web2py Web Framework
If you click on 'cleanup' in 'admin' app then internal error occurs.
Meybe there is problem with deleting session which is currently in
use.
My browser shows 'ticked issued' but there is no ticket in errors dir.
If I click on the ticket link it shows another ticket and after
another click I can view stack trace with:
...
File "F:\tmp\web2py\gluon\restricted.py", line 47, in load
d=cPickle.load(open(file,'rb'))
IOError: [Errno 2] No such file or directory: 'F:/tmp/web2py/
applications/admin/errors/
127.0.0.1.2008-10-30.23-42-31.af87ac0e-0947-49e6-857a-3a169d811d17'

I work with Python 2.5 on Win2000. Do you also can observe this error?

Regards,
Michal

voltron

unread,
Oct 31, 2008, 1:02:07 AM10/31/08
to web2py Web Framework
Hi Michael. You are right, I mentioned this a while back ago. The
decision to remove the link or disable it for Windows is still
pending, right Massimo?

mdipierro

unread,
Oct 31, 2008, 8:51:44 AM10/31/08
to web2py Web Framework
So far this was not removed because it is a windows only problem.
This should be fixed. I would rather not remove the link.

Massimo

mdipierro

unread,
Oct 31, 2008, 10:56:52 AM10/31/08
to web2py Web Framework
Looking into this again....

the problem voltron refers to was fixed. I forgot about it.

In michal case the problem seems to be that the admin/errors folder is
missing. Could you take a look?

perhaps an incomplete installation?

Massimo

Yarko T

unread,
Oct 31, 2008, 11:53:58 AM10/31/08
to web...@googlegroups.com
please note:

If you download web2py in a zip or binary version on PC, I have been finding random errors in Firefox and Chrome browsers - partial downloads which "appear" to be complete (unfortunately this is NOT limited to web2py).   It is somewhat rare, but seems to be completely repeatable for a URL.

I have asked for something in downloads to help validate:   size listings;  separate checksums so you can tell if you have a valid download, etc.

Solutions (instead) I have used:   use bazaar directly to get files;   use cygwin & wget to get files (always seems to succeed).

Micha? Niklas

unread,
Oct 31, 2008, 5:32:14 PM10/31/08
to web...@googlegroups.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

mdipierro pisze:


> Looking into this again....
>
> the problem voltron refers to was fixed. I forgot about it.
>
> In michal case the problem seems to be that the admin/errors folder is
> missing. Could you take a look?
>
> perhaps an incomplete installation?

No, it looks good.
I have unpacked fresh copy of web2py on my second
WinXP machine and it behaves the same :(

Regards,
Michal

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkkLeV4ACgkQhqdZ4syw16xPLwCdGrjs3ouFJNeN7PskFQDPo76Y
rAgAnjQ6grOPnFDclCLktDECc7MAA4D5
=gogL
-----END PGP SIGNATURE-----

mdipierro

unread,
Oct 31, 2008, 5:37:57 PM10/31/08
to web2py Web Framework
ok. I will try reproduce the problem.

On Oct 31, 4:32 pm, Micha? Niklas <michal.nik...@wp.pl> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> mdipierro pisze:
>
> > Looking into this again....
>
> > the problem voltron refers to was fixed. I forgot about it.
>
> > In michal case the problem seems to be that the admin/errors folder is
> > missing. Could you take a look?
>
> > perhaps an incomplete installation?
>
> No, it looks good.
> I have unpacked fresh copy of web2py on my second
> WinXP machine and it behaves the same :(
>
> Regards,
> Michal
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.9 (MingW32)
> Comment: Using GnuPG with Mozilla -http://enigmail.mozdev.org

yarko

unread,
Oct 31, 2008, 6:36:52 PM10/31/08
to web2py Web Framework
I can reproduce this in the latest SVN snapshot - here's the ticket
issued:

------------
Error ticket for "admin"

Ticket 127.0.0.1.2008-10-31.17-30-23.564e6a3d-b43b-40d0-
b729-5713c481786f


Error traceback

1.Traceback (most recent call last):
2. File "D:\Workspace\Web2Py\web2py-trunk\gluon\restricted.py", line
62, in restricted
3. exec ccode in environment
4. File "D:\Workspace\Web2Py\web2py-trunk\applications\admin/
controllers/default.py", line 453, in <module>
5. File "/cygdrive/d/Workspace/Web2Py/web2py-trunk/gluon/globals.py",
line 55, in <lambda>
6. File "D:\Workspace\Web2Py\web2py-trunk\applications\admin/
controllers/default.py", line 205, in cleanup
7. for file in files: os.unlink(file)
8.WindowsError: [Error 32] The process cannot access the file because
it is being used by another process: 9.'D:/Workspace/Web2Py/web2py-
trunk/applications/admin/sessions/127-0-0-1-8c2e3dda-
ffe1-4e01-8960-31a7633c910c'

yarko

unread,
Oct 31, 2008, 6:42:37 PM10/31/08
to web2py Web Framework
Also, in admin app, view errors, check all - and try to delete all
checked results in this ticket, and looking at the .svn/entries file,
I see it's empty (the directory is the file versioned).... so maybe
some special case for the .svn (but what about .bzr, etc, etc.?)

Something to think about....

------------------------
Error ticket for "admin"

Ticket
127.0.0.1.2008-10-31.17-37-35.0875a9f7-4b5c-4a97-8246-3bd2601c50cc


Error traceback

1.Traceback (most recent call last):
2. File "D:\Workspace\Web2Py\web2py-trunk\gluon\restricted.py", line
62, in restricted
3. exec ccode in environment
4. File "D:\Workspace\Web2Py\web2py-trunk\applications\admin/
controllers/default.py", line 453, in <module>
5. File "/cygdrive/d/Workspace/Web2Py/web2py-trunk/gluon/globals.py",
line 55, in <lambda>
6. File "D:\Workspace\Web2Py\web2py-trunk\applications\admin/
controllers/default.py", line 429, in errors
7. os.unlink(apath('%s/errors/%s' % (app,item[7:])))
8.WindowsError: [Error 5] Access is denied: 'D:/Workspace/Web2Py/
web2py-trunk/applications/admin/errors/.svn'
9.

yarko

unread,
Oct 31, 2008, 6:46:13 PM10/31/08
to web2py Web Framework
checking everything _but_ the .svn directory when viewing admin /
errors, and then "remove all checked" worked fine, so I wonder if
this all of these have to do with permissions (read only
directory .svn) on windows...

Should probably skip .svn, .bzr, and .hg (at least ... any others?
What does git use? Does anybody care about cvs?)... or maybe for
error cleanup, there should be a "web2py.ignore" file that an
installation can setup (ala .bzrignore)?

yarko

unread,
Oct 31, 2008, 6:55:57 PM10/31/08
to web2py Web Framework
sorry - clearly these are 2 separate issues.... sessions,
and .svn....

So I checked 2 more things: in applications, examples, giftshop, and
welcome (at least in my install) all have errors/.svn - BUT cleanups
works fine for those apps (in mine, I only had real errors in
giftshop, and a cleanup really cleaned up; none produced any errors).

mdipierro

unread,
Nov 1, 2008, 12:25:00 PM11/1/08
to web2py Web Framework
I think you and Michal may not have upgraded the apps (admin,
examples, welcome) but only the modules. In fact admin/controllers/
default.py, in cleanup() should not contain the line above but

for file in files:
try: os.unlink(file)
except Exception: session.flash=T("cache is in use, errors and
sessions cleaned")

instead. You can fix it by stating web2py with

python web2py.py --upgrade=yes

Notice that when you upgrade web2py, by default, does not upgrade apps
because it does not want to override your code (backward
compatibility!).

Massimo


On Oct 31, 5:36 pm, yarko <yark...@gmail.com> wrote:

Yarko T

unread,
Nov 1, 2008, 2:03:29 PM11/1/08
to web...@googlegroups.com
I've been running from (it turns out) SVN - I'll have to do a compare, because if it's not updated, it's because of the source control / merges...

Perhaps it's time for me to do a "fresh" checkout of web2py?
Reply all
Reply to author
Forward
0 new messages