#490 Some more underscore/dash issues

v1.0.0
closed
nobody
None
General
nobody
2015-08-20
2010-07-07
Anonymous
No

Originally created by: sf-overlords

Created by: mramm
Created date: 2010-06-01 22:35:17.475000
Assigned to:rcopeland

This page works:

https://sourceforge.net/u/mramm/profile/

But this one doesn't:

https://sourceforge.net/u/francois_ld/

Both are linked to from here:

https://sourceforge.net/p/mramm01/ (both are admins of that project).

Oh, and just for kicks I replaced the underscore with a dash, and got this:

https://sourceforge.net/u/francois-ld/profile/

Which is also broken.

Module pyforge.ext.user_profile.user_main:73 in index
<<      def index(self):
               username = c.project.shortname.split('/')[1]
               user = User.by_username(username)
               return dict(user=user)
           # This will be fully implemented in a future iteration
>>  user = User.by_username(username)
Module pyforge.model.auth:169 in by_username
<<      @classmethod
           def by_username(cls, name):
               return plugin.AuthenticationProvider.get(request).by_username(name)

           def address_object(self, addr):
>>  return plugin.AuthenticationProvider.get(request).by_username(name)
Module pyforge.ext.sfx.sfx_main:117 in by_username
<<          except:
                   with fake_pylons_context(self.request):
                       return api.upsert_user(username, extra)

       class SFXProjectRegistrationProvider(plugin.ProjectRegistrationProvider):
>>  return api.upsert_user(username, extra)
Module pyforge.ext.sfx.lib.sfx_api:41 in upsert_user
<<      def upsert_user(self, username, user_data=None):
               if user_data is None:
                   user_data = self.user_data(username)
               u = M.User.query.get(username=username)
               if u is None:
>>  user_data = self.user_data(username)
Module pyforge.ext.sfx.lib.sfx_api:36 in user_data
<<          except ValueError:
                   url = self._username_api_url(username)
               url_handle = urllib2.urlopen(url, timeout=timeout)
               return json.load(url_handle)['User']
>>  url_handle = urllib2.urlopen(url, timeout=timeout)
Module urllib2:124 in urlopen
<<      if _opener is None:
               _opener = build_opener()
           return _opener.open(url, data, timeout)

       def install_opener(opener):
>>  return _opener.open(url, data, timeout)
Module urllib2:389 in open
<<          for processor in self.process_response.get(protocol, []):
                   meth = getattr(processor, meth_name)
                   response = meth(req, response)

               return response
>>  response = meth(req, response)
Module urllib2:502 in http_response
<<          if not (200 <= code < 300):
                   response = self.parent.error(
                       'http', request, response, code, msg, hdrs)

               return response
>>  'http', request, response, code, msg, hdrs)
Module urllib2:427 in error
<<          if http_err:
                   args = (dict, 'default', 'http_error_default') + orig_args
                   return self._call_chain(*args)

       # XXX probably also want an abstract factory that knows when it makes
>>  return self._call_chain(*args)
Module urllib2:361 in _call_chain
<<              func = getattr(handler, meth_name)

                   result = func(*args)
                   if result is not None:
                       return result
>>  result = func(*args)
Module urllib2:510 in http_error_default
<<  class HTTPDefaultErrorHandler(BaseHandler):
           def http_error_default(self, req, fp, code, msg, hdrs):
               raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)

       class HTTPRedirectHandler(BaseHandler):
>>  raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
HTTPError: HTTP Error 404: Not Found

Discussion

  • Anonymous - 2010-07-07

    Originally by: sf-overlords

    Post by mramm:

    • status: code-review --> closed
     
  • Anonymous - 2010-07-07

    Originally by: sf-overlords

    Post by mramm:

    • status: unread --> code-review
     
  • Anonymous - 2010-07-07

    Originally by: sf-overlords

    Post by mramm:

     
  • Anonymous - 2010-07-07

    Originally by: sf-overlords

    Post by mramm:

    description has changed

     

Log in to post a comment.