Float division errors after forking

Issue #98 resolved
Marcin Kuzminski
repo owner created an issue

Here a traceback {{{

!python

URL: http://hg.python-works.com/_admin/repos/Testing-Fork/edit Module weberror.errormiddleware:162 in call << traceback_supplement = Supplement, self, environ sr_checker = ResponseStartChecker(start_response) app_iter = self.application(environ, sr_checker) return self.make_catching_iter(app_iter, environ, sr_checker) except:

app_iter = self.application(environ, sr_checker) Module rhodecode.lib.middleware.simplegit:101 in call << def call(self, environ, start_response): if not is_git(environ): return self.application(environ, start_response)

           proxy_key = 'HTTP_X_REAL_IP'

return self.application(environ, start_response) Module rhodecode.lib.middleware.simplehg:67 in call << def call(self, environ, start_response): if not is_mercurial(environ): return self.application(environ, start_response)

           proxy_key = 'HTTP_X_REAL_IP'

return self.application(environ, start_response) Module beaker.middleware:152 in call << headers.append(('Set-cookie', cookie)) return start_response(status, headers, exc_info) return self.wrap_app(environ, session_start_response)

       def _get_session(self):

return self.wrap_app(environ, session_start_response) Module routes.middleware:131 in call << r'\1', oldpath)

           response = self.app(environ, start_response)

           # Wrapped in try as in rare cases the attribute will be gone already

response = self.app(environ, start_response) Module pylons.wsgiapp:107 in call <<
controller = self.resolve(environ, start_response) response = self.dispatch(controller, environ, start_response)

           if 'paste.testing_variables' in environ and hasattr(response,

response = self.dispatch(controller, environ, start_response) Module pylons.wsgiapp:312 in dispatch << if log_debug: log.debug("Calling controller class with WSGI interface") return controller(environ, start_response)

       def load_test_env(self, environ):

return controller(environ, start_response) Module rhodecode.lib.base:50 in call << #putting this here makes sure that we update permissions every time self.rhodecode_user = c.rhodecode_user = auth.get_user(session) return WSGIController.call(self, environ, start_response) finally: meta.Session.remove() return WSGIController.call(self, environ, start_response) Module pylons.controllers.core:211 in call << return response(environ, self.start_response)

           response = self._dispatch_call()
           if not start_response_called:
               self.start_response = start_response

response = self._dispatch_call() Module pylons.controllers.core:162 in _dispatch_call << req.environ['pylons.action_method'] = func

               response = self._inspect_call(func)
           else:
               if log_debug:

response = self._inspect_call(func) Module pylons.controllers.core:105 in _inspect_call << func.name, args) try: result = self._perform_call(func, args) except HTTPException, httpe: if log_debug: result = self._perform_call(func, args) Module pylons.controllers.core:57 in _perform_call << """Hide the traceback for everything above this method""" traceback_hide = 'before_and_this' return func(**args)

       def _inspect_call(self, func):

return func(**args) Module ?:2 in edit Module rhodecode.lib.auth:379 in wrapper << log.debug('Permission granted for %s %s', func.name__, self.user)

               return func(*fargs, **fkwargs)

           else:

return func(fargs, *fkwargs) Module rhodecode.controllers.admin.repos:296 in edit << else: c.stats_percentage = '%.2f' % ((float((last_rev)) / c.repo_last_rev) * 100)

           defaults = c.repo_info.get_dict()

c.repo_last_rev) * 100) ZeroDivisionError: float division CGI Variables CONTENT_LENGTH '0' CONTENT_TYPE '; charset="utf-8"' HTTP_ACCEPT 'application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,/;q=0.5' HTTP_ACCEPT_CHARSET 'ISO-8859-1,utf-8;q=0.7,*;q=0.3' HTTP_ACCEPT_ENCODING 'gzip,deflate,sdch' HTTP_ACCEPT_LANGUAGE 'en-US,en;q=0.8' HTTP_CONNECTION 'close' HTTP_COOKIE 'rhodecode=c82c97caa915af240f7674ac9789399bd70f9ab37d891ddd038d8978dea352e20f6302f6; utmz=177912124.1294425981.1.1.utmcsr=pypi.python.org|utmccn=(referral)|utmcmd=referral|utmcct=/pypi/RhodeCode/1.0.0rc4; utma=177912124.240258877.1294425981.1294425981.1294425981.1; utmc=177912124; utmb=177912124.9.10.1294425981' HTTP_HOST 'hg.python-works.com' HTTP_PROXY_HOST '127.0.0.1:8002' HTTP_REFERER 'http://hg.python-works.com/Testing-Fork/summary' HTTP_USER_AGENT 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US) AppleWebKit/534.10 (KHTML, like Gecko) Chrome/8.0.552.224 Safari/534.10' HTTP_X_FORWARDED_FOR '50.11.84.218' HTTP_X_HOST 'hg.python-works.com' HTTP_X_REAL_IP '50.11.84.218' HTTP_X_URL_SCHEME 'http' PATH_INFO '/_admin/repos/Testing-Fork/edit' REMOTE_ADDR '127.0.0.1' REQUEST_METHOD 'GET' SERVER_NAME '127.0.0.1' SERVER_PORT '8002' SERVER_PROTOCOL 'HTTP/1.0' WSGI Variables application <rhodecode.lib.middleware.simplegit.SimpleGit object at 0x17788ad0> beaker.get_session <bound method SessionMiddleware._get_session of <beaker.middleware.SessionMiddleware object at 0x165e0450>> beaker.session {'_authentication_token': 'b86c5d1ec53bae29dd18b6ff570c351a3e35115f', 'rhodecode_user': <AuthUser('id:2:demo')>, '_accessed_time': 1294426278.4823871, '_creation_time': 1294425977.2623539} paste.httpserver.thread_pool <paste.httpserver.ThreadPool object at 0x165fad10> paste.registry <paste.registry.Registry object at 0x1ae08350> paste.throw_errors True pylons.action_method <bound method ReposController.edit of <rhodecode.controllers.admin.repos.ReposController object at 0x1cff1590>> pylons.controller <rhodecode.controllers.admin.repos.ReposController object at 0x1cff1590> pylons.environ_config {'session': 'beaker.session', 'cache': 'beaker.cache'} pylons.pylons <pylons.util.PylonsContext object at 0x1ae08cd0> pylons.routes_dict {'action': u'edit', 'controller': u'admin/repos', 'repo_name': u'Testing-Fork'} routes.route <routes.route.Route object at 0x16d34c50> routes.url <routes.util.URLGenerator object at 0x1ae08210> webob.adhoc_attrs {'language': 'en-us'} wsgi process 'Multithreaded' wsgiorg.routing_args (<routes.util.URLGenerator object at 0x1ae08210>, {'action': u'edit', 'controller': u'admin/repos', 'repo_name': u'Testing-Fork'})

}}}

Comments (1)

  1. Log in to comment