oxfam attribute error for photo edit

Bug #698879 reported by Jim B. Glenn
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
KARL3
Fix Released
Medium
Chris Rossi

Bug Description

I think we've already submitted this ticket, and discovered that it was due to oxfam's google appliance running over their karl site, BUT, it is setting off the error monitor regularly.

Can you evaluate the error and surpress it if it's not a valid error?

Reported via error monitor:

ENTRY
Thu Jan 6 18:23:24 2011
Exception when processing https://karl.oxfam.org.uk/profiles/utrnjakov/photo/edit.html
Traceback (most recent call last):
  File "/opt/karl/oxfam/3.5.4-4/src/karl/karl/errorlog.py", line 15, in middleware
    return app(environ, start_response)
  File "/opt/karl/oxfam/3.5.4-4/eggs/repoze.zodbconn-0.11-py2.5.egg/repoze/zodbconn/connector.py", line 21, in __call__
    result = self.next_app(environ, start_response)
  File "/opt/karl/oxfam/3.5.4-4/eggs/repoze.retry-0.9.4-py2.5.egg/repoze/retry/__init__.py", line 88, in __call__
    app_iter = self.application(environ, replace_start_response)
  File "/opt/karl/oxfam/3.5.4-4/eggs/repoze.tm2-1.0a5-py2.5.egg/repoze/tm/__init__.py", line 23, in __call__
    result = self.application(environ, save_status_and_headers)
  File "/opt/karl/oxfam/3.5.4-4/eggs/Paste-1.7.2-py2.5.egg/paste/registry.py", line 350, in __call__
    app_iter = self.application(environ, start_response)
  File "/opt/karl/oxfam/3.5.4-4/eggs/repoze.who-1.0.15-py2.5.egg/repoze/who/middleware.py", line 107, in __call__
    app_iter = app(environ, wrapper.wrap_start_response)
  File "/opt/karl/oxfam/3.5.4-4/eggs/repoze.browserid-0.3-py2.5.egg/repoze/browserid/middleware.py", line 127, in __call__
    return self.app(environ, start_response)
  File "/opt/karl/oxfam/3.5.4-4/eggs/repoze.bfg-1.2-py2.5.egg/repoze/bfg/router.py", line 130, in __call__
    response = view_callable(context, request)
  File "/opt/karl/oxfam/3.5.4-4/eggs/repoze.bfg-1.2-py2.5.egg/repoze/bfg/configuration.py", line 1520, in __call__
    return view(context, request)
  File "/opt/karl/oxfam/3.5.4-4/eggs/repoze.bfg-1.2-py2.5.egg/repoze/bfg/configuration.py", line 1753, in _secured_view
    return view(context, request)
  File "/opt/karl/oxfam/3.5.4-4/eggs/repoze.bfg-1.2-py2.5.egg/repoze/bfg/configuration.py", line 1708, in _rendered_view
    renderer_name)
  File "/opt/karl/oxfam/3.5.4-4/eggs/repoze.bfg-1.2-py2.5.egg/repoze/bfg/configuration.py", line 1562, in rendered_response
    'context':context, 'request':request})
  File "/opt/karl/oxfam/3.5.4-4/eggs/repoze.bfg-1.2-py2.5.egg/repoze/bfg/chameleon_zpt.py", line 46, in __call__
    result = self.template(**system)
  File "/opt/karl/oxfam/3.5.4-4/eggs/Chameleon-1.1.1-py2.5.egg/chameleon/core/template.py", line 83, in __call__
    return self.render(**kwargs)
  File "/opt/karl/oxfam/3.5.4-4/eggs/Chameleon-1.1.1-py2.5.egg/chameleon/core/template.py", line 335, in render
    return super(TemplateFile, self).render(**kwargs)
  File "/opt/karl/oxfam/3.5.4-4/eggs/Chameleon-1.1.1-py2.5.egg/chameleon/zpt/template.py", line 18, in render
    return super(PageTemplate, self).render(**kwargs)
  File "/opt/karl/oxfam/3.5.4-4/eggs/Chameleon-1.1.1-py2.5.egg/chameleon/core/template.py", line 188, in render
    return self.cook_and_render(kwargs, utils.emptydict, None, True)
  File "/opt/karl/oxfam/3.5.4-4/eggs/Chameleon-1.1.1-py2.5.egg/chameleon/core/template.py", line 315, in cook_and_render
    args, slots, macro, global_scope)
  File "/opt/karl/oxfam/3.5.4-4/eggs/Chameleon-1.1.1-py2.5.egg/chameleon/core/template.py", line 180, in cook_and_render
    return func(econtext, rcontext)
  File "<string>", line 135, in render
  File "/opt/karl/oxfam/3.5.4-4/eggs/Chameleon-1.1.1-py2.5.egg/chameleon/core/template.py", line 379, in render
    return self.render(name, slots=slots, parameters=kwargs)
  File "/opt/karl/oxfam/3.5.4-4/eggs/Chameleon-1.1.1-py2.5.egg/chameleon/zpt/template.py", line 23, in render_macro
    macro, global_scope=global_scope, slots=slots, parameters=parameters)
  File "/opt/karl/oxfam/3.5.4-4/eggs/Chameleon-1.1.1-py2.5.egg/chameleon/core/template.py", line 198, in render_macro
    return self.cook_and_render(parameters, slots, macro, global_scope)
  File "/opt/karl/oxfam/3.5.4-4/eggs/Chameleon-1.1.1-py2.5.egg/chameleon/core/template.py", line 315, in cook_and_render
    args, slots, macro, global_scope)
  File "/opt/karl/oxfam/3.5.4-4/eggs/Chameleon-1.1.1-py2.5.egg/chameleon/core/template.py", line 180, in cook_and_render
    return func(econtext, rcontext)
  File "<string>", line 185, in render
  File "/opt/karl/oxfam/3.5.4-4/eggs/Chameleon-1.1.1-py2.5.egg/chameleon/core/codegen.py", line 34, in lookup_attr
    raise e
AttributeError: 'NoneType' object has no attribute 'url'

Tags: r3.54
Revision history for this message
Paul Everitt (paul-agendaless) wrote :

Getting the error monitor back to being useful would be a good thing.

Changed in karl3:
importance: Undecided → Medium
milestone: none → m52
Revision history for this message
Paul Everitt (paul-agendaless) wrote :

Not needed for this next release

Changed in karl3:
assignee: nobody → Chris Rossi (chris-archimedeanco)
Revision history for this message
Chris Rossi (chris-archimedeanco) wrote :

Although, in real life no one should ever be visiting the edit view of a profile view (I'm not sure how people are getting to this url), the error is ultimately caused by a layout provider that isn't smart enough not to return the community layout if the context is not in a community. I have updated the default layout provider in Karl to handle this case and I have updated the customization packages for the partners to use the default layout provider in Karl. In all cases, the partners which were using their layout provider we're using either a provider that was exactly equivalent to the default or, in Oxfam's case, a layout provider that was too basic to really work as intended.

Changed in karl3:
status: New → Fix Committed
Revision history for this message
JimPGlenn (jpglenn09) wrote :

fixed

Changed in karl3:
status: Fix Committed → Fix Released
JimPGlenn (jpglenn09)
tags: added: r3.54
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.