1. Marcin Kuzminski
  2. RhodeCode
  3. Issues

Issues

Issue #795 resolved

Can't browse some repos after upgrade to 1.5.4

Mads Kiilerich
created an issue

Some repositories are not accessible after upgrade from 1.5.1 to 1.5.4. The group works fine, but acessing the repos in it gives:

[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] Error - <class 'sqlalchemy.orm.exc.DetachedInstanceError'>: Parent instance <RepoGroup at 0x7f270d080cd0> is not bound to a Session; lazy load operation of attribute 'parent_group' cannot proceed
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] URL: http://rhodecode-test.hq/learn/Project_Beginner_01/summary
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/WebError-0.10.3-py2.6.egg/weberror/errormiddleware.py', line 162 in __call__
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   app_iter = self.application(environ, sr_checker)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Beaker-1.6.4-py2.6.egg/beaker/middleware.py', line 155 in __call__
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   return self.wrap_app(environ, session_start_response)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Routes-1.13-py2.6.egg/routes/middleware.py', line 131 in __call__
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   response = self.app(environ, start_response)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Pylons-1.0-py2.6.egg/pylons/wsgiapp.py', line 107 in __call__
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   response = self.dispatch(controller, environ, start_response)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Pylons-1.0-py2.6.egg/pylons/wsgiapp.py', line 312 in dispatch
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   return controller(environ, start_response)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/rhodecode/rhodecode/lib/base.py', line 302 in __call__
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   return WSGIController.__call__(self, environ, start_response)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Pylons-1.0-py2.6.egg/pylons/controllers/core.py', line 211 in __call__
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   response = self._dispatch_call()
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Pylons-1.0-py2.6.egg/pylons/controllers/core.py', line 162 in _dispatch_call
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   response = self._inspect_call(func)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Pylons-1.0-py2.6.egg/pylons/controllers/core.py', line 105 in _inspect_call
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   result = self._perform_call(func, args)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Pylons-1.0-py2.6.egg/pylons/controllers/core.py', line 57 in _perform_call
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   return func(**args)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/rhodecode/rhodecode/controllers/summary.py', line 187 in index
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   return render('summary/summary.html')
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Pylons-1.0-py2.6.egg/pylons/templating.py', line 243 in render_mako
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   cache_type=cache_type, cache_expire=cache_expire)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Pylons-1.0-py2.6.egg/pylons/templating.py', line 218 in cached_template
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   return render_func()
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Pylons-1.0-py2.6.egg/pylons/templating.py', line 240 in render_template
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   return literal(template.render_unicode(**globs))
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Mako-0.7.3-py2.6.egg/mako/template.py', line 421 in render_unicode
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   as_unicode=True)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Mako-0.7.3-py2.6.egg/mako/runtime.py', line 766 in _render
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   **_kwargs_for_callable(callable_, data))
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Mako-0.7.3-py2.6.egg/mako/runtime.py', line 798 in _render_context
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   _exec_template(inherit, lclcontext, args=args, kwargs=kwargs)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Mako-0.7.3-py2.6.egg/mako/runtime.py', line 819 in _exec_template
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   _render_error(template, context, e)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Mako-0.7.3-py2.6.egg/mako/runtime.py', line 828 in _render_error
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   result = template.error_handler(context, error)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/Mako-0.7.3-py2.6.egg/mako/runtime.py', line 817 in _exec_template
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   callable_(context, *args, **kwargs)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/data/templates/base/root.html.py', line 68 in render_body
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   __M_writer(escape(next.body()))
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/data/templates/base/base.html.py', line 73 in render_body
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   __M_writer(escape(next.main()))
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/data/templates/summary/summary.html.py', line 80 in render_main
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   __M_writer(escape(self.breadcrumbs()))
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/data/templates/base/base.html.py', line 111 in render_breadcrumbs
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   __M_writer(escape(self.breadcrumbs_links()))
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/data/templates/summary/summary.html.py', line 561 in render_breadcrumbs_links
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   __M_writer(escape(h.repo_link(c.dbrepo.groups_and_repo)))
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/rhodecode/rhodecode/model/db.py', line 849 in groups_and_repo
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   return self.groups_with_parents, self.just_name
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/rhodecode/rhodecode/model/db.py', line 839 in groups_with_parents
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   gr = getattr(cur_gr, 'parent_group', None)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/SQLAlchemy-0.7.9-py2.6-linux-x86_64.egg/sqlalchemy/orm/attributes.py', line 168 in __get__
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   return self.impl.get(instance_state(instance),dict_)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/SQLAlchemy-0.7.9-py2.6-linux-x86_64.egg/sqlalchemy/orm/attributes.py', line 453 in get
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   value = self.callable_(state, passive)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] File '/var/www/rhodecode/venv/lib/python2.6/site-packages/SQLAlchemy-0.7.9-py2.6-linux-x86_64.egg/sqlalchemy/orm/strategies.py', line 481 in _load_for_state
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   (mapperutil.state_str(state), self.key)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] DetachedInstanceError: Parent instance <RepoGroup at 0x7f270d080cd0> is not bound to a Session; lazy load operation of attribute 'parent_group' cannot proceed
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] 
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] 
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] CGI Variables
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] -------------
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   CONTENT_TYPE: '; charset="utf-8"'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   DOCUMENT_ROOT: '/etc/apache2/htdocs'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   GATEWAY_INTERFACE: 'CGI/1.1'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   HTTP_ACCEPT: 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   HTTP_ACCEPT_ENCODING: 'gzip, deflate'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   HTTP_ACCEPT_LANGUAGE: 'en-US,en;q=0.5'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   HTTP_CONNECTION: 'keep-alive'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   HTTP_HOST: 'rhodecode-test.hq'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   HTTP_REFERER: 'http://rhodecode-test.hq/learn/'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   HTTP_USER_AGENT: 'Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:19.0) Gecko/20100101 Firefox/19.0'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   PATH_INFO: '/learn/Project_Beginner_01/summary'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   PATH_TRANSLATED: '/var/www/rhodecode/rhodecode.wsgi/learn/Project_Beginner_01/summary'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   REMOTE_ADDR: '10.45.6.72'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   REMOTE_PORT: '49130'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   REQUEST_METHOD: 'GET'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   REQUEST_URI: '/learn/Project_Beginner_01/summary'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   SCRIPT_FILENAME: '/var/www/rhodecode/rhodecode.wsgi'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   SERVER_ADDR: '10.45.6.47'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   SERVER_ADMIN: 'admin'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   SERVER_NAME: 'rhodecode-test.hq'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   SERVER_PORT: '80'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   SERVER_PROTOCOL: 'HTTP/1.1'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   SERVER_SIGNATURE: '<address>Apache/2.2.16 (Debian) Server at rhodecode-test.hq Port 80</address>\\n'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   SERVER_SOFTWARE: 'Apache/2.2.16 (Debian)'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] 
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] 
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] WSGI Variables
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72] --------------
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   application: <beaker.middleware.SessionMiddleware object at 0x7f270c56bc50>
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   beaker.get_session: <bound method SessionMiddleware._get_session of <beaker.middleware.SessionMiddleware object at 0x7f270c56bc50>>
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   beaker.session: {'_authentication_token': '4e78ee9e96e23907553b0ff239700556bfa043cc', 'rhodecode_user': {'username': u'madski', 'is_authenticated': True, 'user_id': 296}, '_accessed_time': 1363270690.621278, '_creation_time': 1363191416.625071}
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   mod_wsgi.application_group: 'rhodecode.hq|'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   mod_wsgi.callable_object: 'application'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   mod_wsgi.handler_script: ''
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   mod_wsgi.input_chunked: '0'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   mod_wsgi.listener_host: ''
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   mod_wsgi.listener_port: '80'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   mod_wsgi.process_group: 'rhodecode.hq'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   mod_wsgi.request_handler: 'wsgi-script'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   mod_wsgi.script_reloading: '1'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   mod_wsgi.version: (3, 3)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   paste.registry: <paste.registry.Registry object at 0x7f270cfe7490>
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   paste.throw_errors: True
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   pylons.action_method: <bound method SummaryController.index of <rhodecode.controllers.summary.SummaryController object at 0x7f270cff5990>>
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   pylons.controller: <rhodecode.controllers.summary.SummaryController object at 0x7f270cff5990>
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   pylons.environ_config: {'session': 'beaker.session', 'cache': 'beaker.cache'}
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   pylons.pylons: <pylons.util.PylonsContext object at 0x7f270cff5910>
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   pylons.routes_dict: {'action': u'index', 'controller': u'summary', 'repo_name': u'learn/Project_Beginner_01'}
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   routes.cached_hostinfo: {'host': 'rhodecode-test.hq', 'protocol': 'http'}
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   routes.route: <routes.route.Route object at 0x7f270c2574d0>
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   routes.url: <routes.util.URLGenerator object at 0x7f270cff5710>
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   webob._parsed_query_vars: (GET([]), '')
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   webob.adhoc_attrs: {'user': <AuthUser('id:296:madski|True')>, 'language': 'en-us'}
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   wsgi process: 'Multiprocess'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   wsgi._org_proto: 'http'
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   wsgi.file_wrapper: <built-in method file_wrapper of mod_wsgi.Adapter object at 0x7f270cfc2990>
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   wsgi.version: (1, 1)
[Thu Mar 14 15:18:10 2013] [error] [client 10.45.6.72]   wsgiorg.routing_args: (<routes.util.URLGenerator object at 0x7f270cff5710>, {'action': u'index', 'controller': u'summary', 'repo_name': u'learn/Project_Beginner_01'})

Comments (2)

  1. Mads Kiilerich reporter

    This was apparently caused by celery problems.

    1. It is surprising that celery is used at this point - celery problems shouldn't be able to influence simple page navigation. It seems like a bug that celery plays a role here.
    2. The stack trace gives no indication that it should be a celery problem. I guess the error should have been detected and handled somewhere else.
    3. DetachedInstanceError indicates that there is another serious problem.
  2. Log in to comment