Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'NoneType' object has no attribute 'getEventContext' #383

Closed
will-moore opened this issue Jul 5, 2022 · 2 comments · Fixed by #492
Closed

'NoneType' object has no attribute 'getEventContext' #383

will-moore opened this issue Jul 5, 2022 · 2 comments · Fixed by #492

Comments

@will-moore
Copy link
Member

E.g when bsession and server are invalid numbers /webclient/?bsession=1234&server=1234'

Traceback (most recent call last):

  File "/opt/omero/web/venv3/lib64/python3.6/site-packages/django/core/handlers/exception.py", line 47, in inner
    response = get_response(request)

  File "/opt/omero/web/venv3/lib64/python3.6/site-packages/django/core/handlers/base.py", line 181, in _get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)

  File "/opt/omero/web/venv3/lib64/python3.6/site-packages/omeroweb/decorators.py", line 538, in wrapped
    retval = f(request, *args, **kwargs)

  File "/opt/omero/web/venv3/lib64/python3.6/site-packages/omeroweb/decorators.py", line 597, in wrapper
    context = f(request, *args, **kwargs)

  File "/opt/omero/web/venv3/lib64/python3.6/site-packages/omeroweb/webclient/views.py", line 576, in load_template
    return _load_template(request=request, menu=menu, conn=conn, url=url, **kwargs)

  File "/opt/omero/web/venv3/lib64/python3.6/site-packages/omeroweb/webclient/views.py", line 494, in _load_template
    active_group = request.session.get("active_group") or conn.getEventContext().groupId

AttributeError: 'NoneType' object has no attribute 'getEventContext'

<WSGIRequest: GET '/webclient/?bsession=1234&server=1234'>

Also seen on web upgrade when nginx might have cached old session IDs?
https://www.openmicroscopy.org/qa2/qa/feedback/20540/

@gaelrayot-epfl
Copy link

Got the same error when upgrading from OMERO.Web 5.16 to 5.18 or 5.19

@gaelrayot-epfl
Copy link

May be related to #459

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants