Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8992389
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T22:56:34+00:00 2026-06-15T22:56:34+00:00

A couple users complained that they couldn’t get to their authentication settings page on

  • 0

A couple users complained that they couldn’t get to their authentication settings page on OSQA. They receive a 500 error. See Screenshot But, it is only after they go through the “I Forgot My Password” or after changing their password.
Looking at the log, the error specifically is:

UnboundLocalError: local variable name 'name' referenced before assignment  

Has anyone else experienced this? If so, how do I fix it.
Thank you in advance for your help.!!

The Stack Trace from the log reads as follows (Sorry for the poor formatting):

DIRECTORY/forum/templatetags/extra_tags.py TIME: 2012-12-13 09:23:31,419 MSG:extra_tags.py:render:312 Error in declare tag, when evaluating:    questions.children_count('answer')
DIRECTORY/apps/django/lib/python2.6/site-packages/django/core/handlers/base.py TIME: 2012-12-14 12:40:31,086 MSG: base.py:handle_uncaught_exception:209 Internal Server Error: /osqa/account/9/authsettings/
Traceback (most recent call last):
  File "DIRECTORY/apps/django/lib/python2.6/site-packages/django/core/handlers/base.py", line 111, in get_response
    response = callback(request, *callback_args, **callback_kwargs)
  File "DIRECTORY/apps/osqa/forum/views/auth.py", line 348, in auth_settings
    'name': name,
UnboundLocalError: local variable 'name' referenced before assignment
DIRECTORY/apps/osqa/forum/views/meta.py TIME: 2012-12-14 12:40:31,093 MSG: meta.py:error_handler:200 
        error executing request:
        PATH: /osqa/account/9/authsettings/
        USER: USER (1)
        METHOD: GET
        POST PARAMETERS:
            None
        GET PARAMETERS:
            None
        HTTP HEADERS:
            mod_wsgi.listener_port: 8080
    HTTP_REFERER: URL/osqa/users/9/USER
            mod_wsgi.listener_host: 
    SERVER_SOFTWARE: Apache
        SCRIPT_NAME: /osqa
        mod_wsgi.handler_script: 
    SERVER_SIGNATURE: 
    REQUEST_METHOD: GET
    PATH_INFO: /account/9/authsettings/
    SERVER_PROTOCOL: HTTP/1.1
    QUERY_STRING: 
    HTTP_ACCEPT_CHARSET: ISO-8859-1,utf-8;q=0.7,*;q=0.3
    HTTP_USER_AGENT: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.97 Safari/537.11
    HTTP_CONNECTION: keep-alive
    HTTP_COOKIE: sessionid=REDACTED; csrftoken=REDACTED
    SERVER_NAME: SERVERNAME
    REMOTE_ADDR: SERVERIP
    mod_wsgi.request_handler: wsgi-script
    wsgi.url_scheme: http
    PATH_TRANSLATED: DIRECTORY/apache2/htdocs/account/9/authsettings/
    SERVER_PORT: 8080
    wsgi.multiprocess: True
    mod_wsgi.input_chunked: 0
    SERVER_ADDR: SERVERIP
    DOCUMENT_ROOT: DIRECTORY/apache2/htdocs
    mod_wsgi.process_group: 
    SCRIPT_FILENAME: DIRECTORY/apps/osqa/scripts/osqa.wsgi
    SERVER_ADMIN: you@example.com
    wsgi.input: <mod_wsgi.Input object at 0x46feab0>
    HTTP_DNT: 1
    HTTP_HOST: SERVER:8080
    wsgi.multithread: False
    mod_wsgi.callable_object: application
    REQUEST_URI: /osqa/account/9/authsettings/
    HTTP_ACCEPT: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
    wsgi.version: (1, 1)
    GATEWAY_INTERFACE: CGI/1.1
    wsgi.run_once: False
    wsgi.errors: <mod_wsgi.Log object at 0x487c4f0>
    REMOTE_PORT: 51455
    HTTP_ACCEPT_LANGUAGE: en-US,en;q=0.8
    mod_wsgi.version: (3, 3)
    mod_wsgi.application_group: localhost:8080|/osqa
    mod_wsgi.script_reloading: 1
    wsgi.file_wrapper: <built-in method file_wrapper of mod_wsgi.Adapter object at 0x47bf0a8>
    CSRF_COOKIE: REDACTED
    HTTP_ACCEPT_ENCODING: gzip,deflate,sdch

    COOKIES:
             csrftoken: REDACTED
    sessionid: REDACTED

    EXCEPTION INFO:
        Traceback (most recent call last):
      File "DIRECTORY/apps/django/lib/python2.6/site-packages/django/core/handlers/base.py", line 111, in get_response
        response = callback(request, *callback_args, **callback_kwargs)
      File "DIRECTORY/apps/osqa/forum/views/auth.py", line 348, in auth_settings
        'name': name,
    UnboundLocalError: local variable 'name' referenced before assignment
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T22:56:35+00:00Added an answer on June 15, 2026 at 10:56 pm

    Looking at the source code of osqa, here’s what can be found around the lines where you’re having an issue (the line numbers differ from yours, but that’s probably due to a version difference):

    347     for k in auth_keys:
    348         provider = AUTH_PROVIDERS.get(k.provider, None)
    349
    350         if provider is not None:
    351             name =  "%s: %s" % (provider.context.human_name, provider.context.readable_key(k))
    352         else:
    353             from forum.authentication.base import ConsumerTemplateContext
    354             "unknown: %s" % ConsumerTemplateContext.readable_key(k)
    355 
    356         auth_keys_list.append({
    357         'name': name,
    358         'id': k.id
    359         })
    

    Looks like at line 354, we should have name = "unknown: %s" % ConsumerTemplateContext.readable_key(k), but someone forgot that name =.

    I can’t be 100% sure about this, as I am not really knowledgeable in osqa, but this statement doesn’t do anything otherwise if we leave it like it is. Additionally, your bug is 100% reproductible provided you can identify why k.provider isn’t in AUTH_PROVIDERS, which I guess has to be pretty uncommon.


    You might want to file a bug at osqa‘s bug tracker. To solve your issue in the shorter term, you could:

    • Figure out why your provider is None. (Apparently, the issue caused by there being and auth_key for the current user that doesn’t correspond to any of AUTH_PROVIDERS).
    • Fix that line in the code yourself.
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Some of the users of our Ruby on Rails app have complained that page
I've created a search with a couple of comboboxes that allow users to filter
I'm targetting a couple of web projects at mobile users, and noticed that some
I have a couple of table on my database that specify witch users (
I tried to hide a couple of element so that the end users can
I have a couple of buttons that users can click to load content with
I've got a system in which users select a couple of options and receive
We've just decided to purchase Google Apps for Business for a couple of users
couple of quick questions 1) In the local search results - we can get
I posted a free app and I've got a couple users who posted a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.