Well, my student programmer is gone and now suddenly my financials site is not working. It spontaneously asks me to log in, and then gives me an error when I try to view the page. Here's the traceback in the HTML source: <!-- Traceback (innermost last): File /Applications/Zope-2.5.1/lib/python/ZPublisher/Publish.py, line 150, in publish_module File /Applications/Zope-2.5.1/lib/python/ZPublisher/Publish.py, line 114, in publish File /Applications/Zope-2.5.1/lib/python/Zope/__init__.py, line 159, in zpublisher_exception_hook (Object: Financials) File /Applications/Zope-2.5.1/lib/python/ZPublisher/Publish.py, line 98, in publish File /Applications/Zope-2.5.1/lib/python/ZPublisher/mapply.py, line 88, in mapply (Object: index_html) File /Applications/Zope-2.5.1/lib/python/ZPublisher/Publish.py, line 39, in call_object (Object: index_html) File /Applications/Zope-2.5.1/lib/python/OFS/DTMLMethod.py, line 127, in __call__ (Object: index_html) File /Applications/Zope-2.5.1/lib/python/DocumentTemplate/DT_String.py, line 473, in __call__ (Object: index_html) Unauthorized: (see above) --> It looks like an unauthorized error, but I'm the site manager and I haven't restricted access to any pages for myself. This happens randomly throughout my site, including when I just try to go back to the main manage page and have just logged in. In other words, it seems to be forgetting that I'm the manager who has already logged in. I don't know where to start fixing this problem. Can someone give me an idea? Thanks! -- Chris Africa University of Michigan College of Engineering Department of Mechanical Engineering Webmaster/Coordinator, Information Services 734.764.8482
Hi Chris,
Well, my student programmer is gone and now suddenly my financials site is not working.
Tough luck. Use stronger chains next time ;-)
It spontaneously asks me to log in, and then gives me an error when I try to view the page. Here's the traceback in the HTML source:
[snip traceback]
It looks like an unauthorized error, but I'm the site manager and I haven't restricted access to any pages for myself.
[...] I get the same problem irregularily with an admin account defined in a standard (HTTP authorizing) User Folder. Simply logout and login helps to avoid the problem for a while. I did not track down the problem, as it happends rarely and has a simple workaround (for me). Maybe this is actually a browser issue? I get this problem with Mozilla 0.9.9 running on a 2.2.23 Linux kernel, while my Zope is "Zope 2.5.0 (binary release, python 2.1, linux2-x86), python 2.1.2, linux2)" running on a 2.4.17 kernel. (Yes, I _should_ upgrade both, I know ;-) Cheers, Clemens
Chris Africa writes:
Well, my student programmer is gone and now suddenly my financials site is not working.
It spontaneously asks me to log in, and then gives me an error when I try to view the page. Here's the traceback in the HTML source:
We (always!) want "Error type" and "Error value" in addition to a traceback (for the future).
Traceback (innermost last): ... File /Applications/Zope-2.5.1/lib/python/OFS/DTMLMethod.py, line 127, in __call__ (Object: index_html) File /Applications/Zope-2.5.1/lib/python/DocumentTemplate/DT_String.py, line 473, in __call__ (Object: index_html) Unauthorized: (see above) Check the "View permission" of the respective "index_html". Explicitely add "Manager", if it is not there and try again.
If the problem remains, use Shanes "VerboseSecurity" product to find out precisely, what goes wrong. Dieter
I never figured out the source of the unauthorized error, despite playing around with local roles, proxy settings, and security settings (Thanks, Deiter & Clemens for your suggestions). However, I fixed it by creating a new document and copying/pasting the contents of the old into the new, then adjusting the security settings as necessary. Now I get a blank page with header and footer. The code is simple, and it works other places. It is supposed to list the local file systems for which the logged in user has been assigned a local role called "Local," which has only viewing privileges. <dtml-var standard_html_header> <dtml-in expr="aq_parent.objectValues('[Local File System]')" sort="id" skip_unauthorized> <ul> <dtml-if "AUTHENTICATED_USER.has_role('Local',this())"> <li><a href ="/Financials/<dtml-var getId>">#<dtml-var getId></a> </dtml-if> </ul> </dtml-in> <dtml-var standard_html_footer> I found an page on using DTML with LocalFS (http://www.zope.org/Members/jfarr/HowTo/DTML_with_LocalFS) but I'm only a beginning programmer and I'm not sure what modifications need to be made exactly. (Someone else wrote the original.) Searching the 200 MB Zope archive didn't yield any helpful hints. Zope-2.5.1, Mac OSX 10.1.5 Many thanks. Chris On 9/12/02 4:44 PM, "Dieter Maurer" <dieter@handshake.de> wrote:
Chris Africa writes:
Well, my student programmer is gone and now suddenly my financials site is not working.
It spontaneously asks me to log in, and then gives me an error when I try to view the page. Here's the traceback in the HTML source:
We (always!) want "Error type" and "Error value" in addition to a traceback (for the future).
Traceback (innermost last): ... File /Applications/Zope-2.5.1/lib/python/OFS/DTMLMethod.py, line 127, in __call__ (Object: index_html) File /Applications/Zope-2.5.1/lib/python/DocumentTemplate/DT_String.py, line 473, in __call__ (Object: index_html) Unauthorized: (see above) Check the "View permission" of the respective "index_html". Explicitely add "Manager", if it is not there and try again.
If the problem remains, use Shanes "VerboseSecurity" product to find out precisely, what goes wrong.
Dieter
Chris Africa writes:
Now I get a blank page with header and footer. ... <dtml-in expr="aq_parent.objectValues('[Local File System]')" sort="id" skip_unauthorized> Maybe a DTML Document versus Method problem?
Do you have so many "Local File System" objects? Maybe there is none in "aq_parent". Dieter
Hi, Dieter. Yes, there are more than 100 LocalFS objects. The LocalFS objects and index are all at the same level inside the folder "Financials." The code for the index (a DTML document) is using aq_parent as follows: <dtml-in expr="aq_parent.objectValues('[Local File System]')" sort="id" skip_unauthorized> Can you refer me to a page that discusses the "DTML Document versus Method problem"? Chris On 9/13/02 2:09 PM, "Dieter Maurer" <dieter@handshake.de> wrote:
Chris Africa writes:
Now I get a blank page with header and footer. ... <dtml-in expr="aq_parent.objectValues('[Local File System]')" sort="id" skip_unauthorized> Maybe a DTML Document versus Method problem?
Do you have so many "Local File System" objects? Maybe there is none in "aq_parent".
Dieter
Chris Africa writes:
Yes, there are more than 100 LocalFS objects.
The LocalFS objects and index are all at the same level inside the folder "Financials." The code for the index (a DTML document) is using aq_parent as follows:
<dtml-in expr="aq_parent.objectValues('[Local File System]')" sort="id" skip_unauthorized> Not sure, how "aq_parent" works for a DTML Document.
Try to avoid DTML Document in favour of DTML Method. "aq_parent" will then be resolved with respect to the DTML Method's "client". If you do not know what this is, read the "Calling DTML objects" section in <http://www.dieter.handshake.de/pyprojects/zope/book/chap3.html> Dieter
participants (3)
-
Chris Africa -
Clemens Klein-Robbenhaar -
Dieter Maurer