Code

Opened 5 years ago

Closed 5 years ago

Last modified 3 years ago

#9935 closed (wontfix)

The session db backend throws UnicodeEncodeError when used with Oracle

Reported by: jamesli Owned by: nobody
Component: contrib.sessions Version: 1.0
Severity: Keywords: oracle session unicode UnicodeEncodeError
Cc: Goldan Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description (last modified by kmtracey)

I can reproduce the problem with the following environment:
Windows XP Pro
Python 2.5.2
Oracle 10g XE (Universal)
Django 1.0.2 final

(I tend to think it is a Django/Oracle combination problem, because I can't reproduce the bug with MySQL or Postgres.)

I was walking through the tutorial, during which I installed the 'admin' site. I went to http://127.0.0.1:8000/admin/ and logged in with user name and password, and then hit the following error.

UnicodeEncodeError at /admin/

'ascii' codec can't encode characters in position 0-42: ordinal not in range(128)

Request Method: 	POST
Request URL: 	http://127.0.0.1:8000/admin/
Exception Type: 	UnicodeEncodeError
Exception Value: 	

'ascii' codec can't encode characters in position 0-42: ordinal not in range(128)

Exception Location: 	C:\Python25\lib\base64.py in decodestring, line 321
Python Executable: 	C:\Python25\python.exe
Python Version: 	2.5.2
Python Path: 	['C:\\django\\mysite', 'C:\\IBMTOOLS\\utils\\support', 'C:\\IBMTOOLS\\utils\\logger', 'C:\\WINDOWS\\system32\\python25.zip', 'C:\\Python25\\DLLs', 'C:\\Python25\\lib', 'C:\\Python25\\lib\\plat-win', 'C:\\Python25\\lib\\lib-tk', 'C:\\Python25', 'C:\\Python25\\lib\\site-packages']
Server time: 	Tue, 30 Dec 2008 19:42:28 -0800
Unicode error hint

The string that could not be encoded/decoded was: 䅧㥊兣噆湃汒㍣橒㉢爹坡硖汁䝕㉤礹㉡歖兣穎浌穑呏硫坚歊浍㑍呎祉呙硉䝏㉍橙穑呚橊娊則奫婺੬zOTkx


Traceback:
Environment:

Request Method: POST
Request URL: http://127.0.0.1:8000/admin/
Django Version: 1.0.2 final
Python Version: 2.5.2
Installed Applications:
['django.contrib.auth',
 'django.contrib.contenttypes',
 'django.contrib.sessions',
 'django.contrib.sites',
 'django.contrib.admin']
Installed Middleware:
('django.middleware.common.CommonMiddleware',
 'django.contrib.sessions.middleware.SessionMiddleware',
 'django.contrib.auth.middleware.AuthenticationMiddleware')


Traceback:
File "C:\Python25\Lib\site-packages\django\core\handlers\base.py" in get_response
  86.                 response = callback(request, *callback_args, **callback_kwargs)
File "C:\Python25\Lib\site-packages\django\contrib\admin\sites.py" in root
  140.         if not self.has_permission(request):
File "C:\Python25\Lib\site-packages\django\contrib\admin\sites.py" in has_permission
  99.         return request.user.is_authenticated() and request.user.is_staff
File "C:\Python25\Lib\site-packages\django\contrib\auth\middleware.py" in __get__
  5.             request._cached_user = get_user(request)
File "C:\Python25\Lib\site-packages\django\contrib\auth\__init__.py" in get_user
  83.         user_id = request.session[SESSION_KEY]
File "C:\Python25\Lib\site-packages\django\contrib\sessions\backends\base.py" in __getitem__
  46.         return self._session[key]
File "C:\Python25\Lib\site-packages\django\contrib\sessions\backends\base.py" in _get_session
  172.                 self._session_cache = self.load()
File "C:\Python25\Lib\site-packages\django\contrib\sessions\backends\db.py" in load
  18.             return self.decode(force_unicode(s.session_data))
File "C:\Python25\Lib\site-packages\django\contrib\sessions\backends\base.py" in decode
  93.         encoded_data = base64.decodestring(session_data)
File "C:\Python25\lib\base64.py" in decodestring
  321.     return binascii.a2b_base64(s)

Exception Type: UnicodeEncodeError at /admin/
Exception Value: 'ascii' codec can't encode characters in position 0-42: ordinal not in range(128)

Attachments (0)

Change History (11)

comment:1 Changed 5 years ago by kmtracey

  • Component changed from django.contrib.admin to django.contrib.sessions
  • Description modified (diff)
  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset

(Fixed formatting.)

FWIW, this is not generally re-creatable. I've got Oracle 10g XE on a Windows box with Python 2.5.2 and have no trouble using using the admin interface with that setup. I suspect the problem may be some configuration issue but I don't know enough about Oracle or contrib.sessions to say what might be going wrong in your case.

comment:2 Changed 5 years ago by tgarthwaite

  • Keywords session unicode added; admin removed
  • Summary changed from When used with Oracle XE, admin page throws UnicodeEncodeError to The session db backend throws UnicodeEncodeError when used with Oracle

I'm having the same issue against an Oracle 10.2.0.4 database. I'm getting this error at the standard login page (http://lablnx04/accounts/login/). I get the login screen, then after a successful login, this error is thrown.

 
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> 
<html lang="en"> 
<head> 
  <meta http-equiv="content-type" content="text/html; charset=utf-8"> 
  <meta name="robots" content="NONE,NOARCHIVE"> 
  <title>UnicodeDecodeError at /accounts/login/</title> 
  <style type="text/css"> 
    html * { padding:0; margin:0; }
    body * { padding:10px 20px; }
    body * * { padding:0; }
    body { font:small sans-serif; }
    body>div { border-bottom:1px solid #ddd; }
    h1 { font-weight:normal; }
    h2 { margin-bottom:.8em; }
    h2 span { font-size:80%; color:#666; font-weight:normal; }
    h3 { margin:1em 0 .5em 0; }
    h4 { margin:0 0 .5em 0; font-weight: normal; }
    table { border:1px solid #ccc; border-collapse: collapse; width:100%; background:white; }
    tbody td, tbody th { vertical-align:top; padding:2px 3px; }
    thead th { padding:1px 6px 1px 3px; background:#fefefe; text-align:left; font-weight:normal; font-size:11px; border:1px solid #ddd; }
    tbody th { width:12em; text-align:right; color:#666; padding-right:.5em; }
    table.vars { margin:5px 0 2px 40px; }
    table.vars td, table.req td { font-family:monospace; }
    table td.code { width:100%; }
    table td.code div { overflow:hidden; }
    table.source th { color:#666; }
    table.source td { font-family:monospace; white-space:pre; border-bottom:1px solid #eee; }
    ul.traceback { list-style-type:none; }
    ul.traceback li.frame { margin-bottom:1em; }
    div.context { margin: 10px 0; }
    div.context ol { padding-left:30px; margin:0 10px; list-style-position: inside; }
    div.context ol li { font-family:monospace; white-space:pre; color:#666; cursor:pointer; }
    div.context ol.context-line li { color:black; background-color:#ccc; }
    div.context ol.context-line li span { float: right; }
    div.commands { margin-left: 40px; }
    div.commands a { color:black; text-decoration:none; }
    #summary { background: #ffc; }
    #summary h2 { font-weight: normal; color: #666; }
    #explanation { background:#eee; }
    #template, #template-not-exist { background:#f6f6f6; }
    #template-not-exist ul { margin: 0 0 0 20px; }
    #unicode-hint { background:#eee; }
    #traceback { background:#eee; }
    #requestinfo { background:#f6f6f6; padding-left:120px; }
    #summary table { border:none; background:transparent; }
    #requestinfo h2, #requestinfo h3 { position:relative; margin-left:-100px; }
    #requestinfo h3 { margin-bottom:-1em; }
    .error { background: #ffc; }
    .specific { color:#cc3300; font-weight:bold; }
    h2 span.commands { font-size:.7em;}
    span.commands a:link {color:#5E5694;}
    pre.exception_value { font-family: sans-serif; color: #666; font-size: 1.5em; margin: 10px 0 10px 0; }
  </style> 
  <script type="text/javascript"> 
  //<!--
    function getElementsByClassName(oElm, strTagName, strClassName){
        // Written by Jonathan Snook, http://www.snook.ca/jon; Add-ons by Robert Nyman, http://www.robertnyman.com
        var arrElements = (strTagName == "*" && document.all)? document.all :
        oElm.getElementsByTagName(strTagName);
        var arrReturnElements = new Array();
        strClassName = strClassName.replace(/\-/g, "\-");
        var oRegExp = new RegExp("(^|\s)" + strClassName + "(\s|$)");
        var oElement;
        for(var i=0; i<arrElements.length; i++){
            oElement = arrElements[i];
            if(oRegExp.test(oElement.className)){
                arrReturnElements.push(oElement);
            }
        }
        return (arrReturnElements)
    }
    function hideAll(elems) {
      for (var e = 0; e < elems.length; e++) {
        elems[e].style.display = 'none';
      }
    }
    window.onload = function() {
      hideAll(getElementsByClassName(document, 'table', 'vars'));
      hideAll(getElementsByClassName(document, 'ol', 'pre-context'));
      hideAll(getElementsByClassName(document, 'ol', 'post-context'));
      hideAll(getElementsByClassName(document, 'div', 'pastebin'));
    }
    function toggle() {
      for (var i = 0; i < arguments.length; i++) {
        var e = document.getElementById(arguments[i]);
        if (e) {
          e.style.display = e.style.display == 'none' ? 'block' : 'none';
        }
      }
      return false;
    }
    function varToggle(link, id) {
      toggle('v' + id);
      var s = link.getElementsByTagName('span')[0];
      var uarr = String.fromCharCode(0x25b6);
      var darr = String.fromCharCode(0x25bc);
      s.innerHTML = s.innerHTML == uarr ? darr : uarr;
      return false;
    }
    function switchPastebinFriendly(link) {
      s1 = "Switch to copy-and-paste view";
      s2 = "Switch back to interactive view";
      link.innerHTML = link.innerHTML == s1 ? s2 : s1;
      toggle('browserTraceback', 'pastebinTraceback');
      return false;
    }
    //--> 
  </script> 
</head> 
<body> 
<div id="summary"> 
  <h1>UnicodeDecodeError at /accounts/login/</h1> 
  <pre class="exception_value">&#39;utf16&#39; codec can&#39;t decode bytes in position 120-121: illegal UTF-16 surrogate</pre> 
  <table class="meta"> 
    <tr> 
      <th>Request Method:</th> 
      <td>GET</td> 
    </tr> 
    <tr> 
      <th>Request URL:</th> 
      <td>http://lablnx04/accounts/login/</td> 
    </tr> 
    <tr> 
      <th>Exception Type:</th> 
      <td>UnicodeDecodeError</td> 
    </tr> 
    <tr> 
      <th>Exception Value:</th> 
      <td><pre>&#39;utf16&#39; codec can&#39;t decode bytes in position 120-121: illegal UTF-16 surrogate<pre></td> 
    </tr> 
    <tr> 
      <th>Exception Location:</th> 
      <td>/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/backends/oracle/query.py in convert_values, line 59</td> 
    </tr> 
    <tr> 
      <th>Python Executable:</th> 
      <td>/usr/bin/python</td> 
    </tr> 
    <tr> 
      <th>Python Version:</th> 
      <td>2.4.2</td> 
    </tr> 
    <tr> 
      <th>Python Path:</th> 
      <td>[&#39;/usr/local/lib64/python2.4/site-packages/discovery-1.0b-py2.4.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/appirio.gdocs-1.0b-py2.4.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/appirio.google-1.0b-py2.4.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/appirio.imap-1.0b-py2.4.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/appirio.threads-1.0b-py2.4.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/appirio.util-1.0b-py2.4.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/setuptools-0.6c9-py2.4.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/Twisted-8.2.0-py2.4-linux-x86_64.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/enum-0.4.3-py2.4.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/elementtree-1.2.7_20070827_preview-py2.4.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/demjson-1.4-py2.4.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/zope.interface-3.5.0-py2.4-linux-x86_64.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/cx_Oracle-5.0-py2.4-linux-x86_64.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/appirio2.gdocs-1.0b-py2.4.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/appirio2.google-1.0b-py2.4.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/appirio2.imap-1.0b-py2.4.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/appirio2.threads-1.0b.dev_r1309-py2.4.egg&#39;, &#39;/usr/local/lib64/python2.4/site-packages/appirio2.util-1.0b.dev_r1427-py2.4.egg&#39;, &#39;/usr/local/src/appirio.discovery&#39;, &#39;/usr/lib/python24.zip&#39;, &#39;/usr/lib64/python2.4&#39;, &#39;/usr/lib64/python2.4/plat-linux2&#39;, &#39;/usr/lib64/python2.4/lib-tk&#39;, &#39;/usr/lib64/python2.4/lib-dynload&#39;, &#39;/usr/lib64/python2.4/site-packages&#39;, &#39;/usr/lib64/python2.4/site-packages/Numeric&#39;, &#39;/usr/lib64/python2.4/site-packages/dbus&#39;, &#39;/usr/lib64/python2.4/site-packages/gtk-2.0&#39;, &#39;/usr/local/lib64/python2.4/site-packages&#39;]</td> 
    </tr> 
    <tr> 
      <th>Server time:</th> 
      <td>Tue, 6 Jan 2009 07:05:33 -0800</td> 
    </tr> 
  </table> 
</div> 
 
<div id="unicode-hint"> 
    <h2>Unicode error hint</h2> 
    <p>The string that could not be encoded/decoded was: <strong>=Y+��UUU</strong></p> 
</div> 
 
 
 
<div id="traceback"> 
  <h2>Traceback <span class="commands"><a href="#" onclick="return switchPastebinFriendly(this);">Switch to copy-and-paste view</a></span></h2> 
  
  <div id="browserTraceback"> 
    <ul class="traceback"> 
      
        <li class="frame"> 
          <code>/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/core/handlers/base.py</code> in <code>get_response</code> 
 
          
            <div class="context" id="c47662396356440"> 
              
                <ol start="79" class="pre-context" id="pre47662396356440"><li onclick="toggle('pre47662396356440', 'post47662396356440')">            # Apply view middleware</li><li onclick="toggle('pre47662396356440', 'post47662396356440')">            for middleware_method in self._view_middleware:</li><li onclick="toggle('pre47662396356440', 'post47662396356440')">                response = middleware_method(request, callback, callback_args, callback_kwargs)</li><li onclick="toggle('pre47662396356440', 'post47662396356440')">                if response:</li><li onclick="toggle('pre47662396356440', 'post47662396356440')">                    return response</li><li onclick="toggle('pre47662396356440', 'post47662396356440')"></li><li onclick="toggle('pre47662396356440', 'post47662396356440')">            try:</li></ol> 
              
              <ol start="86" class="context-line"><li onclick="toggle('pre47662396356440', 'post47662396356440')">                response = callback(request, *callback_args, **callback_kwargs) <span>...</span></li></ol> 
              
                <ol start='87' class="post-context" id="post47662396356440"><li onclick="toggle('pre47662396356440', 'post47662396356440')">            except Exception, e:</li><li onclick="toggle('pre47662396356440', 'post47662396356440')">                # If the view raised an exception, run it through exception</li><li onclick="toggle('pre47662396356440', 'post47662396356440')">                # middleware, and if the exception middleware returns a</li><li onclick="toggle('pre47662396356440', 'post47662396356440')">                # response, use that. Otherwise, reraise the exception.</li><li onclick="toggle('pre47662396356440', 'post47662396356440')">                for middleware_method in self._exception_middleware:</li><li onclick="toggle('pre47662396356440', 'post47662396356440')">                    response = middleware_method(request, e)</li></ol> 
              
            </div> 
          
 
          
            <div class="commands"> 
                <a href="#" onclick="return varToggle(this, '47662396356440')"><span>&#x25b6;</span> Local vars</a> 
            </div> 
            <table class="vars" id="v47662396356440"> 
              <thead> 
                <tr> 
                  <th>Variable</th> 
                  <th>Value</th> 
                </tr> 
              </thead> 
              <tbody> 
                
                  <tr> 
                    <td>callback</td> 
                    <td class="code"><div>&lt;function login at 0x2b594431be60&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>callback_args</td> 
                    <td class="code"><div>()</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>callback_kwargs</td> 
                    <td class="code"><div>{}</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>e</td> 
                    <td class="code"><div>&lt;exceptions.UnicodeDecodeError instance at 0x2b5944343320&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>exc_info</td> 
                    <td class="code"><div>(&lt;class exceptions.UnicodeDecodeError at 0x2b593d9dfc50&gt;,
 &lt;exceptions.UnicodeDecodeError instance at 0x2b5944343320&gt;,
 &lt;traceback object at 0x2b5944343758&gt;)</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>exceptions</td> 
                    <td class="code"><div>&lt;module &#39;django.core.exceptions&#39; from &#39;/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/core/exceptions.pyc&#39;&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>middleware_method</td> 
                    <td class="code"><div>&lt;bound method XViewMiddleware.process_view of &lt;django.middleware.doc.XViewMiddleware object at 0x2b5941fbd150&gt;&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>receivers</td> 
                    <td class="code"><div>[(&lt;function _rollback_on_exception at 0x2b5943fa46e0&gt;, None)]</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>request</td> 
                    <td class="code"><div>&lt;ModPythonRequest
path:/accounts/login/,
GET:&lt;QueryDict: {}&gt;,
POST:&lt;QueryDict: {}&gt;,
COOKIES:{&#39;sessionid&#39;: &#39;33c96f240174a0b7e67bd90ccf9b1764&#39;},
META:{&#39;AUTH_TYPE&#39;: None,
 &#39;CONTENT_LENGTH&#39;: 0L,
 &#39;CONTENT_TYPE&#39;: None,
 &#39;GATEWAY_INTERFACE&#39;: &#39;CGI/1.1&#39;,
 &#39;HTTP_ACCEPT&#39;: &#39;text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5&#39;,
 &#39;HTTP_ACCEPT_CHARSET&#39;: &#39;ISO-8859-1,*,utf-8&#39;,
 &#39;HTTP_ACCEPT_ENCODING&#39;: &#39;gzip,deflate,bzip2,sdch&#39;,
 &#39;HTTP_ACCEPT_LANGUAGE&#39;: &#39;en-US,en&#39;,
 &#39;HTTP_CACHE_CONTROL&#39;: &#39;max-age=0&#39;,
 &#39;HTTP_CONNECTION&#39;: &#39;Keep-Alive&#39;,
 &#39;HTTP_COOKIE&#39;: &#39;sessionid=33c96f240174a0b7e67bd90ccf9b1764&#39;,
 &#39;HTTP_HOST&#39;: &#39;lablnx04&#39;,
 &#39;HTTP_USER_AGENT&#39;: &#39;Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US) AppleWebKit/525.19 (KHTML, like Gecko) Chrome/1.0.154.36 Safari/525.19&#39;,
 &#39;PATH_INFO&#39;: u&#39;/accounts/login/&#39;,
 &#39;PATH_TRANSLATED&#39;: None,
 &#39;QUERY_STRING&#39;: None,
 &#39;REMOTE_ADDR&#39;: &#39;172.31.1.81&#39;,
 &#39;REMOTE_HOST&#39;: None,
 &#39;REMOTE_IDENT&#39;: None,
 &#39;REMOTE_USER&#39;: None,
 &#39;REQUEST_METHOD&#39;: &#39;GET&#39;,
 &#39;SCRIPT_NAME&#39;: &#39;/edisco&#39;,
 &#39;SERVER_NAME&#39;: &#39;lablnx04.gene.com&#39;,
 &#39;SERVER_PORT&#39;: 0,
 &#39;SERVER_PROTOCOL&#39;: &#39;HTTP/1.1&#39;,
 &#39;SERVER_SOFTWARE&#39;: &#39;mod_python&#39;}&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>resolver</td> 
                    <td class="code"><div>&lt;RegexURLResolver discovery.urls ^/&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>response</td> 
                    <td class="code"><div>None</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>self</td> 
                    <td class="code"><div>&lt;django.core.handlers.modpython.ModPythonHandler object at 0x2b5940d20e50&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>settings</td> 
                    <td class="code"><div>&lt;django.conf.LazySettings object at 0x2b5941a3a410&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>urlconf</td> 
                    <td class="code"><div>&#39;discovery.urls&#39;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>urlresolvers</td> 
                    <td class="code"><div>&lt;module &#39;django.core.urlresolvers&#39; from &#39;/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/core/urlresolvers.pyc&#39;&gt;</div></td> 
                  </tr> 
                
              </tbody> 
            </table> 
          
        </li> 
      
        <li class="frame"> 
          <code>/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/views/decorators/cache.py</code> in <code>_wrapped_view_func</code> 
 
          
            <div class="context" id="c47662396356368"> 
              
                <ol start="37" class="pre-context" id="pre47662396356368"><li onclick="toggle('pre47662396356368', 'post47662396356368')"></li><li onclick="toggle('pre47662396356368', 'post47662396356368')">def never_cache(view_func):</li><li onclick="toggle('pre47662396356368', 'post47662396356368')">    &quot;&quot;&quot;</li><li onclick="toggle('pre47662396356368', 'post47662396356368')">    Decorator that adds headers to a response so that it will</li><li onclick="toggle('pre47662396356368', 'post47662396356368')">    never be cached.</li><li onclick="toggle('pre47662396356368', 'post47662396356368')">    &quot;&quot;&quot;</li><li onclick="toggle('pre47662396356368', 'post47662396356368')">    def _wrapped_view_func(request, *args, **kwargs):</li></ol> 
              
              <ol start="44" class="context-line"><li onclick="toggle('pre47662396356368', 'post47662396356368')">        response = view_func(request, *args, **kwargs) <span>...</span></li></ol> 
              
                <ol start='45' class="post-context" id="post47662396356368"><li onclick="toggle('pre47662396356368', 'post47662396356368')">        add_never_cache_headers(response)</li><li onclick="toggle('pre47662396356368', 'post47662396356368')">        return response</li><li onclick="toggle('pre47662396356368', 'post47662396356368')">    return wraps(view_func)(_wrapped_view_func)</li></ol> 
              
            </div> 
          
 
          
            <div class="commands"> 
                <a href="#" onclick="return varToggle(this, '47662396356368')"><span>&#x25b6;</span> Local vars</a> 
            </div> 
            <table class="vars" id="v47662396356368"> 
              <thead> 
                <tr> 
                  <th>Variable</th> 
                  <th>Value</th> 
                </tr> 
              </thead> 
              <tbody> 
                
                  <tr> 
                    <td>args</td> 
                    <td class="code"><div>()</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>kwargs</td> 
                    <td class="code"><div>{}</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>request</td> 
                    <td class="code"><div>&lt;ModPythonRequest
path:/accounts/login/,
GET:&lt;QueryDict: {}&gt;,
POST:&lt;QueryDict: {}&gt;,
COOKIES:{&#39;sessionid&#39;: &#39;33c96f240174a0b7e67bd90ccf9b1764&#39;},
META:{&#39;AUTH_TYPE&#39;: None,
 &#39;CONTENT_LENGTH&#39;: 0L,
 &#39;CONTENT_TYPE&#39;: None,
 &#39;GATEWAY_INTERFACE&#39;: &#39;CGI/1.1&#39;,
 &#39;HTTP_ACCEPT&#39;: &#39;text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5&#39;,
 &#39;HTTP_ACCEPT_CHARSET&#39;: &#39;ISO-8859-1,*,utf-8&#39;,
 &#39;HTTP_ACCEPT_ENCODING&#39;: &#39;gzip,deflate,bzip2,sdch&#39;,
 &#39;HTTP_ACCEPT_LANGUAGE&#39;: &#39;en-US,en&#39;,
 &#39;HTTP_CACHE_CONTROL&#39;: &#39;max-age=0&#39;,
 &#39;HTTP_CONNECTION&#39;: &#39;Keep-Alive&#39;,
 &#39;HTTP_COOKIE&#39;: &#39;sessionid=33c96f240174a0b7e67bd90ccf9b1764&#39;,
 &#39;HTTP_HOST&#39;: &#39;lablnx04&#39;,
 &#39;HTTP_USER_AGENT&#39;: &#39;Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US) AppleWebKit/525.19 (KHTML, like Gecko) Chrome/1.0.154.36 Safari/525.19&#39;,
 &#39;PATH_INFO&#39;: u&#39;/accounts/login/&#39;,
 &#39;PATH_TRANSLATED&#39;: None,
 &#39;QUERY_STRING&#39;: None,
 &#39;REMOTE_ADDR&#39;: &#39;172.31.1.81&#39;,
 &#39;REMOTE_HOST&#39;: None,
 &#39;REMOTE_IDENT&#39;: None,
 &#39;REMOTE_USER&#39;: None,
 &#39;REQUEST_METHOD&#39;: &#39;GET&#39;,
 &#39;SCRIPT_NAME&#39;: &#39;/edisco&#39;,
 &#39;SERVER_NAME&#39;: &#39;lablnx04.gene.com&#39;,
 &#39;SERVER_PORT&#39;: 0,
 &#39;SERVER_PROTOCOL&#39;: &#39;HTTP/1.1&#39;,
 &#39;SERVER_SOFTWARE&#39;: &#39;mod_python&#39;}&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>view_func</td> 
                    <td class="code"><div>&lt;function login at 0x2b594431bde8&gt;</div></td> 
                  </tr> 
                
              </tbody> 
            </table> 
          
        </li> 
      
        <li class="frame"> 
          <code>/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/contrib/auth/views.py</code> in <code>login</code> 
 
          
            <div class="context" id="c47662396356296"> 
              
                <ol start="26" class="pre-context" id="pre47662396356296"><li onclick="toggle('pre47662396356296', 'post47662396356296')">            from django.contrib.auth import login</li><li onclick="toggle('pre47662396356296', 'post47662396356296')">            login(request, form.get_user())</li><li onclick="toggle('pre47662396356296', 'post47662396356296')">            if request.session.test_cookie_worked():</li><li onclick="toggle('pre47662396356296', 'post47662396356296')">                request.session.delete_test_cookie()</li><li onclick="toggle('pre47662396356296', 'post47662396356296')">            return HttpResponseRedirect(redirect_to)</li><li onclick="toggle('pre47662396356296', 'post47662396356296')">    else:</li><li onclick="toggle('pre47662396356296', 'post47662396356296')">        form = AuthenticationForm(request)</li></ol> 
              
              <ol start="33" class="context-line"><li onclick="toggle('pre47662396356296', 'post47662396356296')">    request.session.set_test_cookie() <span>...</span></li></ol> 
              
                <ol start='34' class="post-context" id="post47662396356296"><li onclick="toggle('pre47662396356296', 'post47662396356296')">    if Site._meta.installed:</li><li onclick="toggle('pre47662396356296', 'post47662396356296')">        current_site = Site.objects.get_current()</li><li onclick="toggle('pre47662396356296', 'post47662396356296')">    else:</li><li onclick="toggle('pre47662396356296', 'post47662396356296')">        current_site = RequestSite(request)</li><li onclick="toggle('pre47662396356296', 'post47662396356296')">    return render_to_response(template_name, {</li><li onclick="toggle('pre47662396356296', 'post47662396356296')">        &#39;form&#39;: form,</li></ol> 
              
            </div> 
          
 
          
            <div class="commands"> 
                <a href="#" onclick="return varToggle(this, '47662396356296')"><span>&#x25b6;</span> Local vars</a> 
            </div> 
            <table class="vars" id="v47662396356296"> 
              <thead> 
                <tr> 
                  <th>Variable</th> 
                  <th>Value</th> 
                </tr> 
              </thead> 
              <tbody> 
                
                  <tr> 
                    <td>form</td> 
                    <td class="code"><div>&lt;django.contrib.auth.forms.AuthenticationForm object at 0x2b5944284810&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>redirect_field_name</td> 
                    <td class="code"><div>&#39;next&#39;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>redirect_to</td> 
                    <td class="code"><div>&#39;&#39;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>request</td> 
                    <td class="code"><div>&lt;ModPythonRequest
path:/accounts/login/,
GET:&lt;QueryDict: {}&gt;,
POST:&lt;QueryDict: {}&gt;,
COOKIES:{&#39;sessionid&#39;: &#39;33c96f240174a0b7e67bd90ccf9b1764&#39;},
META:{&#39;AUTH_TYPE&#39;: None,
 &#39;CONTENT_LENGTH&#39;: 0L,
 &#39;CONTENT_TYPE&#39;: None,
 &#39;GATEWAY_INTERFACE&#39;: &#39;CGI/1.1&#39;,
 &#39;HTTP_ACCEPT&#39;: &#39;text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5&#39;,
 &#39;HTTP_ACCEPT_CHARSET&#39;: &#39;ISO-8859-1,*,utf-8&#39;,
 &#39;HTTP_ACCEPT_ENCODING&#39;: &#39;gzip,deflate,bzip2,sdch&#39;,
 &#39;HTTP_ACCEPT_LANGUAGE&#39;: &#39;en-US,en&#39;,
 &#39;HTTP_CACHE_CONTROL&#39;: &#39;max-age=0&#39;,
 &#39;HTTP_CONNECTION&#39;: &#39;Keep-Alive&#39;,
 &#39;HTTP_COOKIE&#39;: &#39;sessionid=33c96f240174a0b7e67bd90ccf9b1764&#39;,
 &#39;HTTP_HOST&#39;: &#39;lablnx04&#39;,
 &#39;HTTP_USER_AGENT&#39;: &#39;Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US) AppleWebKit/525.19 (KHTML, like Gecko) Chrome/1.0.154.36 Safari/525.19&#39;,
 &#39;PATH_INFO&#39;: u&#39;/accounts/login/&#39;,
 &#39;PATH_TRANSLATED&#39;: None,
 &#39;QUERY_STRING&#39;: None,
 &#39;REMOTE_ADDR&#39;: &#39;172.31.1.81&#39;,
 &#39;REMOTE_HOST&#39;: None,
 &#39;REMOTE_IDENT&#39;: None,
 &#39;REMOTE_USER&#39;: None,
 &#39;REQUEST_METHOD&#39;: &#39;GET&#39;,
 &#39;SCRIPT_NAME&#39;: &#39;/edisco&#39;,
 &#39;SERVER_NAME&#39;: &#39;lablnx04.gene.com&#39;,
 &#39;SERVER_PORT&#39;: 0,
 &#39;SERVER_PROTOCOL&#39;: &#39;HTTP/1.1&#39;,
 &#39;SERVER_SOFTWARE&#39;: &#39;mod_python&#39;}&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>template_name</td> 
                    <td class="code"><div>&#39;registration/login.html&#39;</div></td> 
                  </tr> 
                
              </tbody> 
            </table> 
          
        </li> 
      
        <li class="frame"> 
          <code>/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/contrib/sessions/backends/base.py</code> in <code>set_test_cookie</code> 
 
          
            <div class="context" id="c47662395555496"> 
              
                <ol start="71" class="pre-context" id="pre47662395555496"><li onclick="toggle('pre47662395555496', 'post47662395555496')">            return self._session[key]</li><li onclick="toggle('pre47662395555496', 'post47662395555496')">        else:</li><li onclick="toggle('pre47662395555496', 'post47662395555496')">            self.modified = True</li><li onclick="toggle('pre47662395555496', 'post47662395555496')">            self._session[key] = value</li><li onclick="toggle('pre47662395555496', 'post47662395555496')">            return value</li><li onclick="toggle('pre47662395555496', 'post47662395555496')"></li><li onclick="toggle('pre47662395555496', 'post47662395555496')">    def set_test_cookie(self):</li></ol> 
              
              <ol start="78" class="context-line"><li onclick="toggle('pre47662395555496', 'post47662395555496')">        self[self.TEST_COOKIE_NAME] = self.TEST_COOKIE_VALUE <span>...</span></li></ol> 
              
                <ol start='79' class="post-context" id="post47662395555496"><li onclick="toggle('pre47662395555496', 'post47662395555496')"></li><li onclick="toggle('pre47662395555496', 'post47662395555496')">    def test_cookie_worked(self):</li><li onclick="toggle('pre47662395555496', 'post47662395555496')">        return self.get(self.TEST_COOKIE_NAME) == self.TEST_COOKIE_VALUE</li><li onclick="toggle('pre47662395555496', 'post47662395555496')"></li><li onclick="toggle('pre47662395555496', 'post47662395555496')">    def delete_test_cookie(self):</li><li onclick="toggle('pre47662395555496', 'post47662395555496')">        del self[self.TEST_COOKIE_NAME]</li></ol> 
              
            </div> 
          
 
          
            <div class="commands"> 
                <a href="#" onclick="return varToggle(this, '47662395555496')"><span>&#x25b6;</span> Local vars</a> 
            </div> 
            <table class="vars" id="v47662395555496"> 
              <thead> 
                <tr> 
                  <th>Variable</th> 
                  <th>Value</th> 
                </tr> 
              </thead> 
              <tbody> 
                
                  <tr> 
                    <td>self</td> 
                    <td class="code"><div>&lt;django.contrib.sessions.backends.db.SessionStore object at 0x2b5941fd0090&gt;</div></td> 
                  </tr> 
                
              </tbody> 
            </table> 
          
        </li> 
      
        <li class="frame"> 
          <code>/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/contrib/sessions/backends/base.py</code> in <code>__setitem__</code> 
 
          
            <div class="context" id="c47662395555568"> 
              
                <ol start="42" class="pre-context" id="pre47662395555568"><li onclick="toggle('pre47662395555568', 'post47662395555568')">    def __contains__(self, key):</li><li onclick="toggle('pre47662395555568', 'post47662395555568')">        return key in self._session</li><li onclick="toggle('pre47662395555568', 'post47662395555568')"></li><li onclick="toggle('pre47662395555568', 'post47662395555568')">    def __getitem__(self, key):</li><li onclick="toggle('pre47662395555568', 'post47662395555568')">        return self._session[key]</li><li onclick="toggle('pre47662395555568', 'post47662395555568')"></li><li onclick="toggle('pre47662395555568', 'post47662395555568')">    def __setitem__(self, key, value):</li></ol> 
              
              <ol start="49" class="context-line"><li onclick="toggle('pre47662395555568', 'post47662395555568')">        self._session[key] = value <span>...</span></li></ol> 
              
                <ol start='50' class="post-context" id="post47662395555568"><li onclick="toggle('pre47662395555568', 'post47662395555568')">        self.modified = True</li><li onclick="toggle('pre47662395555568', 'post47662395555568')"></li><li onclick="toggle('pre47662395555568', 'post47662395555568')">    def __delitem__(self, key):</li><li onclick="toggle('pre47662395555568', 'post47662395555568')">        del self._session[key]</li><li onclick="toggle('pre47662395555568', 'post47662395555568')">        self.modified = True</li><li onclick="toggle('pre47662395555568', 'post47662395555568')"></li></ol> 
              
            </div> 
          
 
          
            <div class="commands"> 
                <a href="#" onclick="return varToggle(this, '47662395555568')"><span>&#x25b6;</span> Local vars</a> 
            </div> 
            <table class="vars" id="v47662395555568"> 
              <thead> 
                <tr> 
                  <th>Variable</th> 
                  <th>Value</th> 
                </tr> 
              </thead> 
              <tbody> 
                
                  <tr> 
                    <td>key</td> 
                    <td class="code"><div>&#39;testcookie&#39;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>self</td> 
                    <td class="code"><div>&lt;django.contrib.sessions.backends.db.SessionStore object at 0x2b5941fd0090&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>value</td> 
                    <td class="code"><div>&#39;worked&#39;</div></td> 
                  </tr> 
                
              </tbody> 
            </table> 
          
        </li> 
      
        <li class="frame"> 
          <code>/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/contrib/sessions/backends/base.py</code> in <code>_get_session</code> 
 
          
            <div class="context" id="c47662396356224"> 
              
                <ol start="165" class="pre-context" id="pre47662396356224"><li onclick="toggle('pre47662396356224', 'post47662396356224')">        self.accessed = True</li><li onclick="toggle('pre47662396356224', 'post47662396356224')">        try:</li><li onclick="toggle('pre47662396356224', 'post47662396356224')">            return self._session_cache</li><li onclick="toggle('pre47662396356224', 'post47662396356224')">        except AttributeError:</li><li onclick="toggle('pre47662396356224', 'post47662396356224')">            if self._session_key is None or no_load:</li><li onclick="toggle('pre47662396356224', 'post47662396356224')">                self._session_cache = {}</li><li onclick="toggle('pre47662396356224', 'post47662396356224')">            else:</li></ol> 
              
              <ol start="172" class="context-line"><li onclick="toggle('pre47662396356224', 'post47662396356224')">                self._session_cache = self.load() <span>...</span></li></ol> 
              
                <ol start='173' class="post-context" id="post47662396356224"><li onclick="toggle('pre47662396356224', 'post47662396356224')">        return self._session_cache</li><li onclick="toggle('pre47662396356224', 'post47662396356224')"></li><li onclick="toggle('pre47662396356224', 'post47662396356224')">    _session = property(_get_session)</li><li onclick="toggle('pre47662396356224', 'post47662396356224')"></li><li onclick="toggle('pre47662396356224', 'post47662396356224')">    def get_expiry_age(self):</li><li onclick="toggle('pre47662396356224', 'post47662396356224')">        &quot;&quot;&quot;Get the number of seconds until the session expires.&quot;&quot;&quot;</li></ol> 
              
            </div> 
          
 
          
            <div class="commands"> 
                <a href="#" onclick="return varToggle(this, '47662396356224')"><span>&#x25b6;</span> Local vars</a> 
            </div> 
            <table class="vars" id="v47662396356224"> 
              <thead> 
                <tr> 
                  <th>Variable</th> 
                  <th>Value</th> 
                </tr> 
              </thead> 
              <tbody> 
                
                  <tr> 
                    <td>no_load</td> 
                    <td class="code"><div>False</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>self</td> 
                    <td class="code"><div>&lt;django.contrib.sessions.backends.db.SessionStore object at 0x2b5941fd0090&gt;</div></td> 
                  </tr> 
                
              </tbody> 
            </table> 
          
        </li> 
      
        <li class="frame"> 
          <code>/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/contrib/sessions/backends/db.py</code> in <code>load</code> 
 
          
            <div class="context" id="c47662396356152"> 
              
                <ol start="9" class="pre-context" id="pre47662396356152"><li onclick="toggle('pre47662396356152', 'post47662396356152')">    &quot;&quot;&quot;</li><li onclick="toggle('pre47662396356152', 'post47662396356152')">    Implements database session store.</li><li onclick="toggle('pre47662396356152', 'post47662396356152')">    &quot;&quot;&quot;</li><li onclick="toggle('pre47662396356152', 'post47662396356152')">    def load(self):</li><li onclick="toggle('pre47662396356152', 'post47662396356152')">        try:</li><li onclick="toggle('pre47662396356152', 'post47662396356152')">            s = Session.objects.get(</li><li onclick="toggle('pre47662396356152', 'post47662396356152')">                session_key = self.session_key,</li></ol> 
              
              <ol start="16" class="context-line"><li onclick="toggle('pre47662396356152', 'post47662396356152')">                expire_date__gt=datetime.datetime.now() <span>...</span></li></ol> 
              
                <ol start='17' class="post-context" id="post47662396356152"><li onclick="toggle('pre47662396356152', 'post47662396356152')">            )</li><li onclick="toggle('pre47662396356152', 'post47662396356152')">            return self.decode(force_unicode(s.session_data))</li><li onclick="toggle('pre47662396356152', 'post47662396356152')">        except (Session.DoesNotExist, SuspiciousOperation):</li><li onclick="toggle('pre47662396356152', 'post47662396356152')">            self.create()</li><li onclick="toggle('pre47662396356152', 'post47662396356152')">            return {}</li><li onclick="toggle('pre47662396356152', 'post47662396356152')"></li></ol> 
              
            </div> 
          
 
          
            <div class="commands"> 
                <a href="#" onclick="return varToggle(this, '47662396356152')"><span>&#x25b6;</span> Local vars</a> 
            </div> 
            <table class="vars" id="v47662396356152"> 
              <thead> 
                <tr> 
                  <th>Variable</th> 
                  <th>Value</th> 
                </tr> 
              </thead> 
              <tbody> 
                
                  <tr> 
                    <td>self</td> 
                    <td class="code"><div>&lt;django.contrib.sessions.backends.db.SessionStore object at 0x2b5941fd0090&gt;</div></td> 
                  </tr> 
                
              </tbody> 
            </table> 
          
        </li> 
      
        <li class="frame"> 
          <code>/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/models/manager.py</code> in <code>get</code> 
 
          
            <div class="context" id="c47662396356080"> 
              
                <ol start="86" class="pre-context" id="pre47662396356080"><li onclick="toggle('pre47662396356080', 'post47662396356080')">    def distinct(self, *args, **kwargs):</li><li onclick="toggle('pre47662396356080', 'post47662396356080')">        return self.get_query_set().distinct(*args, **kwargs)</li><li onclick="toggle('pre47662396356080', 'post47662396356080')"></li><li onclick="toggle('pre47662396356080', 'post47662396356080')">    def extra(self, *args, **kwargs):</li><li onclick="toggle('pre47662396356080', 'post47662396356080')">        return self.get_query_set().extra(*args, **kwargs)</li><li onclick="toggle('pre47662396356080', 'post47662396356080')"></li><li onclick="toggle('pre47662396356080', 'post47662396356080')">    def get(self, *args, **kwargs):</li></ol> 
              
              <ol start="93" class="context-line"><li onclick="toggle('pre47662396356080', 'post47662396356080')">        return self.get_query_set().get(*args, **kwargs) <span>...</span></li></ol> 
              
                <ol start='94' class="post-context" id="post47662396356080"><li onclick="toggle('pre47662396356080', 'post47662396356080')"></li><li onclick="toggle('pre47662396356080', 'post47662396356080')">    def get_or_create(self, **kwargs):</li><li onclick="toggle('pre47662396356080', 'post47662396356080')">        return self.get_query_set().get_or_create(**kwargs)</li><li onclick="toggle('pre47662396356080', 'post47662396356080')"></li><li onclick="toggle('pre47662396356080', 'post47662396356080')">    def create(self, **kwargs):</li><li onclick="toggle('pre47662396356080', 'post47662396356080')">        return self.get_query_set().create(**kwargs)</li></ol> 
              
            </div> 
          
 
          
            <div class="commands"> 
                <a href="#" onclick="return varToggle(this, '47662396356080')"><span>&#x25b6;</span> Local vars</a> 
            </div> 
            <table class="vars" id="v47662396356080"> 
              <thead> 
                <tr> 
                  <th>Variable</th> 
                  <th>Value</th> 
                </tr> 
              </thead> 
              <tbody> 
                
                  <tr> 
                    <td>args</td> 
                    <td class="code"><div>()</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>kwargs</td> 
                    <td class="code"><div>{&#39;expire_date__gt&#39;: datetime.datetime(2009, 1, 6, 7, 5, 33, 566372),
 &#39;session_key&#39;: &#39;33c96f240174a0b7e67bd90ccf9b1764&#39;}</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>self</td> 
                    <td class="code"><div>&lt;django.contrib.sessions.models.SessionManager object at 0x2b594416fa50&gt;</div></td> 
                  </tr> 
                
              </tbody> 
            </table> 
          
        </li> 
      
        <li class="frame"> 
          <code>/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/models/query.py</code> in <code>get</code> 
 
          
            <div class="context" id="c47662396051328"> 
              
                <ol start="297" class="pre-context" id="pre47662396051328"><li onclick="toggle('pre47662396051328', 'post47662396051328')"></li><li onclick="toggle('pre47662396051328', 'post47662396051328')">    def get(self, *args, **kwargs):</li><li onclick="toggle('pre47662396051328', 'post47662396051328')">        &quot;&quot;&quot;</li><li onclick="toggle('pre47662396051328', 'post47662396051328')">        Performs the query and returns a single object matching the given</li><li onclick="toggle('pre47662396051328', 'post47662396051328')">        keyword arguments.</li><li onclick="toggle('pre47662396051328', 'post47662396051328')">        &quot;&quot;&quot;</li><li onclick="toggle('pre47662396051328', 'post47662396051328')">        clone = self.filter(*args, **kwargs)</li></ol> 
              
              <ol start="304" class="context-line"><li onclick="toggle('pre47662396051328', 'post47662396051328')">        num = len(clone) <span>...</span></li></ol> 
              
                <ol start='305' class="post-context" id="post47662396051328"><li onclick="toggle('pre47662396051328', 'post47662396051328')">        if num == 1:</li><li onclick="toggle('pre47662396051328', 'post47662396051328')">            return clone._result_cache[0]</li><li onclick="toggle('pre47662396051328', 'post47662396051328')">        if not num:</li><li onclick="toggle('pre47662396051328', 'post47662396051328')">            raise self.model.DoesNotExist(&quot;%s matching query does not exist.&quot;</li><li onclick="toggle('pre47662396051328', 'post47662396051328')">                    % self.model._meta.object_name)</li><li onclick="toggle('pre47662396051328', 'post47662396051328')">        raise self.model.MultipleObjectsReturned(&quot;get() returned more than one %s -- it returned %s! Lookup parameters were %s&quot;</li></ol> 
              
            </div> 
          
 
          
            <div class="commands"> 
                <a href="#" onclick="return varToggle(this, '47662396051328')"><span>&#x25b6;</span> Local vars</a> 
            </div> 
            <table class="vars" id="v47662396051328"> 
              <thead> 
                <tr> 
                  <th>Variable</th> 
                  <th>Value</th> 
                </tr> 
              </thead> 
              <tbody> 
                
                  <tr> 
                    <td>args</td> 
                    <td class="code"><div>()</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>clone</td> 
                    <td class="code"><div>[&lt;Session: Session object&gt;]</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>kwargs</td> 
                    <td class="code"><div>{&#39;expire_date__gt&#39;: datetime.datetime(2009, 1, 6, 7, 5, 33, 566372),
 &#39;session_key&#39;: &#39;33c96f240174a0b7e67bd90ccf9b1764&#39;}</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>self</td> 
                    <td class="code"><div>[&lt;Session: Session object&gt;, &lt;Session: Session object&gt;, &lt;Session: Session object&gt;, &lt;Session: Session object&gt;, &lt;Session: Session object&gt;]</div></td> 
                  </tr> 
                
              </tbody> 
            </table> 
          
        </li> 
      
        <li class="frame"> 
          <code>/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/models/query.py</code> in <code>__len__</code> 
 
          
            <div class="context" id="c47662396050968"> 
              
                <ol start="153" class="pre-context" id="pre47662396050968"><li onclick="toggle('pre47662396050968', 'post47662396050968')">        # Since __len__ is called quite frequently (for example, as part of</li><li onclick="toggle('pre47662396050968', 'post47662396050968')">        # list(qs), we make some effort here to be as efficient as possible</li><li onclick="toggle('pre47662396050968', 'post47662396050968')">        # whilst not messing up any existing iterators against the QuerySet.</li><li onclick="toggle('pre47662396050968', 'post47662396050968')">        if self._result_cache is None:</li><li onclick="toggle('pre47662396050968', 'post47662396050968')">            if self._iter:</li><li onclick="toggle('pre47662396050968', 'post47662396050968')">                self._result_cache = list(self._iter)</li><li onclick="toggle('pre47662396050968', 'post47662396050968')">            else:</li></ol> 
              
              <ol start="160" class="context-line"><li onclick="toggle('pre47662396050968', 'post47662396050968')">                self._result_cache = list(self.iterator()) <span>...</span></li></ol> 
              
                <ol start='161' class="post-context" id="post47662396050968"><li onclick="toggle('pre47662396050968', 'post47662396050968')">        elif self._iter:</li><li onclick="toggle('pre47662396050968', 'post47662396050968')">            self._result_cache.extend(list(self._iter))</li><li onclick="toggle('pre47662396050968', 'post47662396050968')">        return len(self._result_cache)</li><li onclick="toggle('pre47662396050968', 'post47662396050968')"></li><li onclick="toggle('pre47662396050968', 'post47662396050968')">    def __iter__(self):</li><li onclick="toggle('pre47662396050968', 'post47662396050968')">        if self._result_cache is None:</li></ol> 
              
            </div> 
          
 
          
            <div class="commands"> 
                <a href="#" onclick="return varToggle(this, '47662396050968')"><span>&#x25b6;</span> Local vars</a> 
            </div> 
            <table class="vars" id="v47662396050968"> 
              <thead> 
                <tr> 
                  <th>Variable</th> 
                  <th>Value</th> 
                </tr> 
              </thead> 
              <tbody> 
                
                  <tr> 
                    <td>self</td> 
                    <td class="code"><div>[&lt;Session: Session object&gt;]</div></td> 
                  </tr> 
                
              </tbody> 
            </table> 
          
        </li> 
      
        <li class="frame"> 
          <code>/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/models/query.py</code> in <code>iterator</code> 
 
          
            <div class="context" id="c47662396356008"> 
              
                <ol start="268" class="pre-context" id="pre47662396356008"><li onclick="toggle('pre47662396356008', 'post47662396356008')">        if isinstance(fill_cache, dict):</li><li onclick="toggle('pre47662396356008', 'post47662396356008')">            requested = fill_cache</li><li onclick="toggle('pre47662396356008', 'post47662396356008')">        else:</li><li onclick="toggle('pre47662396356008', 'post47662396356008')">            requested = None</li><li onclick="toggle('pre47662396356008', 'post47662396356008')">        max_depth = self.query.max_depth</li><li onclick="toggle('pre47662396356008', 'post47662396356008')">        extra_select = self.query.extra_select.keys()</li><li onclick="toggle('pre47662396356008', 'post47662396356008')">        index_start = len(extra_select)</li></ol> 
              
              <ol start="275" class="context-line"><li onclick="toggle('pre47662396356008', 'post47662396356008')">        for row in self.query.results_iter(): <span>...</span></li></ol> 
              
                <ol start='276' class="post-context" id="post47662396356008"><li onclick="toggle('pre47662396356008', 'post47662396356008')">            if fill_cache:</li><li onclick="toggle('pre47662396356008', 'post47662396356008')">                obj, _ = get_cached_row(self.model, row, index_start,</li><li onclick="toggle('pre47662396356008', 'post47662396356008')">                        max_depth, requested=requested)</li><li onclick="toggle('pre47662396356008', 'post47662396356008')">            else:</li><li onclick="toggle('pre47662396356008', 'post47662396356008')">                obj = self.model(*row[index_start:])</li><li onclick="toggle('pre47662396356008', 'post47662396356008')">            for i, k in enumerate(extra_select):</li></ol> 
              
            </div> 
          
 
          
            <div class="commands"> 
                <a href="#" onclick="return varToggle(this, '47662396356008')"><span>&#x25b6;</span> Local vars</a> 
            </div> 
            <table class="vars" id="v47662396356008"> 
              <thead> 
                <tr> 
                  <th>Variable</th> 
                  <th>Value</th> 
                </tr> 
              </thead> 
              <tbody> 
                
                  <tr> 
                    <td>extra_select</td> 
                    <td class="code"><div>[]</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>fill_cache</td> 
                    <td class="code"><div>False</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>index_start</td> 
                    <td class="code"><div>0</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>max_depth</td> 
                    <td class="code"><div>5</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>requested</td> 
                    <td class="code"><div>None</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>self</td> 
                    <td class="code"><div>[&lt;Session: Session object&gt;]</div></td> 
                  </tr> 
                
              </tbody> 
            </table> 
          
        </li> 
      
        <li class="frame"> 
          <code>/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/models/sql/query.py</code> in <code>results_iter</code> 
 
          
            <div class="context" id="c47662396355216"> 
              
                <ol start="210" class="pre-context" id="pre47662396355216"><li onclick="toggle('pre47662396355216', 'post47662396355216')">                        # We only set this up here because</li><li onclick="toggle('pre47662396355216', 'post47662396355216')">                        # related_select_fields isn&#39;t populated until</li><li onclick="toggle('pre47662396355216', 'post47662396355216')">                        # execute_sql() has been called.</li><li onclick="toggle('pre47662396355216', 'post47662396355216')">                        if self.select_fields:</li><li onclick="toggle('pre47662396355216', 'post47662396355216')">                            fields = self.select_fields + self.related_select_fields</li><li onclick="toggle('pre47662396355216', 'post47662396355216')">                        else:</li><li onclick="toggle('pre47662396355216', 'post47662396355216')">                            fields = self.model._meta.fields</li></ol> 
              
              <ol start="217" class="context-line"><li onclick="toggle('pre47662396355216', 'post47662396355216')">                    row = self.resolve_columns(row, fields) <span>...</span></li></ol> 
              
                <ol start='218' class="post-context" id="post47662396355216"><li onclick="toggle('pre47662396355216', 'post47662396355216')">                yield row</li><li onclick="toggle('pre47662396355216', 'post47662396355216')"></li><li onclick="toggle('pre47662396355216', 'post47662396355216')">    def get_count(self):</li><li onclick="toggle('pre47662396355216', 'post47662396355216')">        &quot;&quot;&quot;</li><li onclick="toggle('pre47662396355216', 'post47662396355216')">        Performs a COUNT() query using the current filter constraints.</li><li onclick="toggle('pre47662396355216', 'post47662396355216')">        &quot;&quot;&quot;</li></ol> 
              
            </div> 
          
 
          
            <div class="commands"> 
                <a href="#" onclick="return varToggle(this, '47662396355216')"><span>&#x25b6;</span> Local vars</a> 
            </div> 
            <table class="vars" id="v47662396355216"> 
              <thead> 
                <tr> 
                  <th>Variable</th> 
                  <th>Value</th> 
                </tr> 
              </thead> 
              <tbody> 
                
                  <tr> 
                    <td>fields</td> 
                    <td class="code"><div>[&lt;django.db.models.fields.CharField object at 0x2b5941fd0610&gt;,
 &lt;django.db.models.fields.TextField object at 0x2b5944168950&gt;,
 &lt;django.db.models.fields.DateTimeField object at 0x2b594416fa10&gt;]</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>resolve_columns</td> 
                    <td class="code"><div>True</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>row</td> 
                    <td class="code"><div>(u&#39;33c96f240174a0b7e67bd90ccf9b1764&#39;,
 &lt;cx_Oracle.LOB object at 0x2b593da1e6f0&gt;,
 datetime.datetime(2009, 1, 20, 6, 59, 17, 672334))</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>rows</td> 
                    <td class="code"><div>((u&#39;33c96f240174a0b7e67bd90ccf9b1764&#39;,
  &lt;cx_Oracle.LOB object at 0x2b593da1e6f0&gt;,
  datetime.datetime(2009, 1, 20, 6, 59, 17, 672334)),)</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>self</td> 
                    <td class="code"><div>&lt;django.db.backends.oracle.query.OracleQuery object at 0x2b594431c490&gt;</div></td> 
                  </tr> 
                
              </tbody> 
            </table> 
          
        </li> 
      
        <li class="frame"> 
          <code>/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/backends/oracle/query.py</code> in <code>resolve_columns</code> 
 
          
            <div class="context" id="c47662396355864"> 
              
                <ol start="45" class="pre-context" id="pre47662396355864"><li onclick="toggle('pre47662396355864', 'post47662396355864')">                rn_offset = 1</li><li onclick="toggle('pre47662396355864', 'post47662396355864')">            else:</li><li onclick="toggle('pre47662396355864', 'post47662396355864')">                rn_offset = 0</li><li onclick="toggle('pre47662396355864', 'post47662396355864')">            index_start = rn_offset + len(self.extra_select.keys())</li><li onclick="toggle('pre47662396355864', 'post47662396355864')">            values = [self.convert_values(v, None)</li><li onclick="toggle('pre47662396355864', 'post47662396355864')">                      for v in row[rn_offset:index_start]]</li><li onclick="toggle('pre47662396355864', 'post47662396355864')">            for value, field in map(None, row[index_start:], fields):</li></ol> 
              
              <ol start="52" class="context-line"><li onclick="toggle('pre47662396355864', 'post47662396355864')">                values.append(self.convert_values(value, field)) <span>...</span></li></ol> 
              
                <ol start='53' class="post-context" id="post47662396355864"><li onclick="toggle('pre47662396355864', 'post47662396355864')">            return values</li><li onclick="toggle('pre47662396355864', 'post47662396355864')"></li><li onclick="toggle('pre47662396355864', 'post47662396355864')">        def convert_values(self, value, field):</li><li onclick="toggle('pre47662396355864', 'post47662396355864')">            from django.db.models.fields import DateField, DateTimeField, \</li><li onclick="toggle('pre47662396355864', 'post47662396355864')">                 TimeField, BooleanField, NullBooleanField, DecimalField, Field</li><li onclick="toggle('pre47662396355864', 'post47662396355864')">            if isinstance(value, Database.LOB):</li></ol> 
              
            </div> 
          
 
          
            <div class="commands"> 
                <a href="#" onclick="return varToggle(this, '47662396355864')"><span>&#x25b6;</span> Local vars</a> 
            </div> 
            <table class="vars" id="v47662396355864"> 
              <thead> 
                <tr> 
                  <th>Variable</th> 
                  <th>Value</th> 
                </tr> 
              </thead> 
              <tbody> 
                
                  <tr> 
                    <td>field</td> 
                    <td class="code"><div>&lt;django.db.models.fields.TextField object at 0x2b5944168950&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>fields</td> 
                    <td class="code"><div>[&lt;django.db.models.fields.CharField object at 0x2b5941fd0610&gt;,
 &lt;django.db.models.fields.TextField object at 0x2b5944168950&gt;,
 &lt;django.db.models.fields.DateTimeField object at 0x2b594416fa10&gt;]</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>index_start</td> 
                    <td class="code"><div>0</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>rn_offset</td> 
                    <td class="code"><div>0</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>row</td> 
                    <td class="code"><div>(u&#39;33c96f240174a0b7e67bd90ccf9b1764&#39;,
 &lt;cx_Oracle.LOB object at 0x2b593da1e6f0&gt;,
 datetime.datetime(2009, 1, 20, 6, 59, 17, 672334))</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>self</td> 
                    <td class="code"><div>&lt;django.db.backends.oracle.query.OracleQuery object at 0x2b594431c490&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>value</td> 
                    <td class="code"><div>&lt;cx_Oracle.LOB object at 0x2b593da1e6f0&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>values</td> 
                    <td class="code"><div>[u&#39;33c96f240174a0b7e67bd90ccf9b1764&#39;]</div></td> 
                  </tr> 
                
              </tbody> 
            </table> 
          
        </li> 
      
        <li class="frame"> 
          <code>/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/backends/oracle/query.py</code> in <code>convert_values</code> 
 
          
            <div class="context" id="c47662396355936"> 
              
                <ol start="52" class="pre-context" id="pre47662396355936"><li onclick="toggle('pre47662396355936', 'post47662396355936')">                values.append(self.convert_values(value, field))</li><li onclick="toggle('pre47662396355936', 'post47662396355936')">            return values</li><li onclick="toggle('pre47662396355936', 'post47662396355936')"></li><li onclick="toggle('pre47662396355936', 'post47662396355936')">        def convert_values(self, value, field):</li><li onclick="toggle('pre47662396355936', 'post47662396355936')">            from django.db.models.fields import DateField, DateTimeField, \</li><li onclick="toggle('pre47662396355936', 'post47662396355936')">                 TimeField, BooleanField, NullBooleanField, DecimalField, Field</li><li onclick="toggle('pre47662396355936', 'post47662396355936')">            if isinstance(value, Database.LOB):</li></ol> 
              
              <ol start="59" class="context-line"><li onclick="toggle('pre47662396355936', 'post47662396355936')">                value = value.read() <span>...</span></li></ol> 
              
                <ol start='60' class="post-context" id="post47662396355936"><li onclick="toggle('pre47662396355936', 'post47662396355936')">            # Oracle stores empty strings as null. We need to undo this in</li><li onclick="toggle('pre47662396355936', 'post47662396355936')">            # order to adhere to the Django convention of using the empty</li><li onclick="toggle('pre47662396355936', 'post47662396355936')">            # string instead of null, but only if the field accepts the</li><li onclick="toggle('pre47662396355936', 'post47662396355936')">            # empty string.</li><li onclick="toggle('pre47662396355936', 'post47662396355936')">            if value is None and isinstance(field, Field) and field.empty_strings_allowed:</li><li onclick="toggle('pre47662396355936', 'post47662396355936')">                value = u&#39;&#39;</li></ol> 
              
            </div> 
          
 
          
            <div class="commands"> 
                <a href="#" onclick="return varToggle(this, '47662396355936')"><span>&#x25b6;</span> Local vars</a> 
            </div> 
            <table class="vars" id="v47662396355936"> 
              <thead> 
                <tr> 
                  <th>Variable</th> 
                  <th>Value</th> 
                </tr> 
              </thead> 
              <tbody> 
                
                  <tr> 
                    <td>BooleanField</td> 
                    <td class="code"><div>&lt;class &#39;django.db.models.fields.BooleanField&#39;&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>Database</td> 
                    <td class="code"><div>&lt;module &#39;cx_Oracle&#39; from &#39;/tmp/cx_Oracle-5.0-py2.4-linux-x86_64.egg-tmp/cx_Oracle.so&#39;&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>DateField</td> 
                    <td class="code"><div>&lt;class &#39;django.db.models.fields.DateField&#39;&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>DateTimeField</td> 
                    <td class="code"><div>&lt;class &#39;django.db.models.fields.DateTimeField&#39;&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>DecimalField</td> 
                    <td class="code"><div>&lt;class &#39;django.db.models.fields.DecimalField&#39;&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>Field</td> 
                    <td class="code"><div>&lt;class &#39;django.db.models.fields.Field&#39;&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>NullBooleanField</td> 
                    <td class="code"><div>&lt;class &#39;django.db.models.fields.NullBooleanField&#39;&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>TimeField</td> 
                    <td class="code"><div>&lt;class &#39;django.db.models.fields.TimeField&#39;&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>field</td> 
                    <td class="code"><div>&lt;django.db.models.fields.TextField object at 0x2b5944168950&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>self</td> 
                    <td class="code"><div>&lt;django.db.backends.oracle.query.OracleQuery object at 0x2b594431c490&gt;</div></td> 
                  </tr> 
                
                  <tr> 
                    <td>value</td> 
                    <td class="code"><div>&lt;cx_Oracle.LOB object at 0x2b593da1e6f0&gt;</div></td> 
                  </tr> 
                
              </tbody> 
            </table> 
          
        </li> 
      
    </ul> 
  </div> 
  
  <form action="http://dpaste.com/" name="pasteform" id="pasteform" method="post"> 
  <div id="pastebinTraceback" class="pastebin"> 
    <input type="hidden" name="language" value="PythonConsole"> 
    <input type="hidden" name="title" value="UnicodeDecodeError at /accounts/login/"> 
    <input type="hidden" name="source" value="Django Dpaste Agent"> 
    <input type="hidden" name="poster" value="Django"> 
    <textarea name="content" id="traceback_area" cols="140" rows="25"> 
Environment:
 
Request Method: GET
Request URL: http://lablnx04/accounts/login/
Django Version: 1.0.2 final
Python Version: 2.4.2
Installed Applications:
[&#39;django.contrib.admin&#39;,
 &#39;django.contrib.auth&#39;,
 &#39;django.contrib.contenttypes&#39;,
 &#39;django.contrib.sessions&#39;,
 &#39;django.contrib.sites&#39;,
 &#39;discovery.edisco&#39;]
Installed Middleware:
(&#39;django.middleware.common.CommonMiddleware&#39;,
 &#39;django.contrib.sessions.middleware.SessionMiddleware&#39;,
 &#39;django.contrib.auth.middleware.AuthenticationMiddleware&#39;,
 &#39;django.middleware.doc.XViewMiddleware&#39;)
 
 
Traceback:
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/core/handlers/base.py" in get_response
  86.                 response = callback(request, *callback_args, **callback_kwargs)
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/views/decorators/cache.py" in _wrapped_view_func
  44.         response = view_func(request, *args, **kwargs)
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/contrib/auth/views.py" in login
  33.     request.session.set_test_cookie()
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/contrib/sessions/backends/base.py" in set_test_cookie
  78.         self[self.TEST_COOKIE_NAME] = self.TEST_COOKIE_VALUE
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/contrib/sessions/backends/base.py" in __setitem__
  49.         self._session[key] = value
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/contrib/sessions/backends/base.py" in _get_session
  172.                 self._session_cache = self.load()
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/contrib/sessions/backends/db.py" in load
  16.                 expire_date__gt=datetime.datetime.now()
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/models/manager.py" in get
  93.         return self.get_query_set().get(*args, **kwargs)
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/models/query.py" in get
  304.         num = len(clone)
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/models/query.py" in __len__
  160.                 self._result_cache = list(self.iterator())
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/models/query.py" in iterator
  275.         for row in self.query.results_iter():
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/models/sql/query.py" in results_iter
  217.                     row = self.resolve_columns(row, fields)
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/backends/oracle/query.py" in resolve_columns
  52.                 values.append(self.convert_values(value, field))
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/backends/oracle/query.py" in convert_values
  59.                 value = value.read()
 
Exception Type: UnicodeDecodeError at /accounts/login/
Exception Value: &#39;utf16&#39; codec can&#39;t decode bytes in position 120-121: illegal UTF-16 surrogate
</textarea> 
  <br><br> 
  <input type="submit" value="Share this traceback on a public Web site"> 
  </div> 
</form> 
</div> 
 
<div id="requestinfo"> 
  <h2>Request information</h2> 
 
  <h3 id="get-info">GET</h3> 
  
    <p>No GET data</p> 
  
 
  <h3 id="post-info">POST</h3> 
  
    <p>No POST data</p> 
  
 
  <h3 id="cookie-info">COOKIES</h3> 
  
    <table class="req"> 
      <thead> 
        <tr> 
          <th>Variable</th> 
          <th>Value</th> 
        </tr> 
      </thead> 
      <tbody> 
        
          <tr> 
            <td>sessionid</td> 
            <td class="code"><div>&#39;33c96f240174a0b7e67bd90ccf9b1764&#39;</div></td> 
          </tr> 
        
      </tbody> 
    </table> 
  
 
  <h3 id="meta-info">META</h3> 
  <table class="req"> 
    <thead> 
      <tr> 
        <th>Variable</th> 
        <th>Value</th> 
      </tr> 
    </thead> 
    <tbody> 
      
        <tr> 
          <td>AUTH_TYPE</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>CONTENT_LENGTH</td> 
          <td class="code"><div>0L</div></td> 
        </tr> 
      
        <tr> 
          <td>CONTENT_TYPE</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>GATEWAY_INTERFACE</td> 
          <td class="code"><div>&#39;CGI/1.1&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>HTTP_ACCEPT</td> 
          <td class="code"><div>&#39;text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>HTTP_ACCEPT_CHARSET</td> 
          <td class="code"><div>&#39;ISO-8859-1,*,utf-8&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>HTTP_ACCEPT_ENCODING</td> 
          <td class="code"><div>&#39;gzip,deflate,bzip2,sdch&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>HTTP_ACCEPT_LANGUAGE</td> 
          <td class="code"><div>&#39;en-US,en&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>HTTP_CACHE_CONTROL</td> 
          <td class="code"><div>&#39;max-age=0&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>HTTP_CONNECTION</td> 
          <td class="code"><div>&#39;Keep-Alive&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>HTTP_COOKIE</td> 
          <td class="code"><div>&#39;sessionid=33c96f240174a0b7e67bd90ccf9b1764&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>HTTP_HOST</td> 
          <td class="code"><div>&#39;lablnx04&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>HTTP_USER_AGENT</td> 
          <td class="code"><div>&#39;Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US) AppleWebKit/525.19 (KHTML, like Gecko) Chrome/1.0.154.36 Safari/525.19&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>PATH_INFO</td> 
          <td class="code"><div>u&#39;/accounts/login/&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>PATH_TRANSLATED</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>QUERY_STRING</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>REMOTE_ADDR</td> 
          <td class="code"><div>&#39;172.31.1.81&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>REMOTE_HOST</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>REMOTE_IDENT</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>REMOTE_USER</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>REQUEST_METHOD</td> 
          <td class="code"><div>&#39;GET&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>SCRIPT_NAME</td> 
          <td class="code"><div>&#39;/edisco&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>SERVER_NAME</td> 
          <td class="code"><div>&#39;lablnx04.gene.com&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>SERVER_PORT</td> 
          <td class="code"><div>0</div></td> 
        </tr> 
      
        <tr> 
          <td>SERVER_PROTOCOL</td> 
          <td class="code"><div>&#39;HTTP/1.1&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>SERVER_SOFTWARE</td> 
          <td class="code"><div>&#39;mod_python&#39;</div></td> 
        </tr> 
      
    </tbody> 
  </table> 
 
  <h3 id="settings-info">Settings</h3> 
  <h4>Using settings module <code>discovery.settings</code></h4> 
  <table class="req"> 
    <thead> 
      <tr> 
        <th>Setting</th> 
        <th>Value</th> 
      </tr> 
    </thead> 
    <tbody> 
      
        <tr> 
          <td>ABSOLUTE_URL_OVERRIDES</td> 
          <td class="code"><div>{}</div></td> 
        </tr> 
      
        <tr> 
          <td>ADMINS</td> 
          <td class="code"><div>()</div></td> 
        </tr> 
      
        <tr> 
          <td>ADMIN_FOR</td> 
          <td class="code"><div>()</div></td> 
        </tr> 
      
        <tr> 
          <td>ADMIN_MEDIA_PREFIX</td> 
          <td class="code"><div>&#39;/media/&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>ALLOWED_INCLUDE_ROOTS</td> 
          <td class="code"><div>()</div></td> 
        </tr> 
      
        <tr> 
          <td>APPEND_SLASH</td> 
          <td class="code"><div>True</div></td> 
        </tr> 
      
        <tr> 
          <td>AUTHENTICATION_BACKENDS</td> 
          <td class="code"><div>(&#39;django.contrib.auth.backends.ModelBackend&#39;,
 &#39;discovery.ldap_backend.LDAPBackend&#39;)</div></td> 
        </tr> 
      
        <tr> 
          <td>BANNED_IPS</td> 
          <td class="code"><div>()</div></td> 
        </tr> 
      
        <tr> 
          <td>CACHE_BACKEND</td> 
          <td class="code"><div>&#39;locmem://&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>CACHE_MIDDLEWARE_KEY_PREFIX</td> 
          <td class="code"><div>&#39;&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>CACHE_MIDDLEWARE_SECONDS</td> 
          <td class="code"><div>600</div></td> 
        </tr> 
      
        <tr> 
          <td>COMMENTS_ALLOW_PROFANITIES</td> 
          <td class="code"><div>False</div></td> 
        </tr> 
      
        <tr> 
          <td>COMMENTS_BANNED_USERS_GROUP</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>COMMENTS_FIRST_FEW</td> 
          <td class="code"><div>0</div></td> 
        </tr> 
      
        <tr> 
          <td>COMMENTS_MODERATORS_GROUP</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>COMMENTS_SKETCHY_USERS_GROUP</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>DATABASE_ENGINE</td> 
          <td class="code"><div>&#39;oracle&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>DATABASE_HOST</td> 
          <td class="code"><div>&#39;citd4.gene.com&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>DATABASE_NAME</td> 
          <td class="code"><div>&#39;citd4&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>DATABASE_OPTIONS</td> 
          <td class="code"><div>{}</div></td> 
        </tr> 
      
        <tr> 
          <td>DATABASE_PASSWORD</td> 
          <td class="code"><div>&#39;********************&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>DATABASE_PORT</td> 
          <td class="code"><div>&#39;50047&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>DATABASE_USER</td> 
          <td class="code"><div>&#39;mail_discovery&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>DATETIME_FORMAT</td> 
          <td class="code"><div>&#39;N j, Y, P&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>DATE_FORMAT</td> 
          <td class="code"><div>&#39;N j, Y&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>DEBUG</td> 
          <td class="code"><div>True</div></td> 
        </tr> 
      
        <tr> 
          <td>DEBUG_PROPAGATE_EXCEPTIONS</td> 
          <td class="code"><div>False</div></td> 
        </tr> 
      
        <tr> 
          <td>DEFAULT_CHARSET</td> 
          <td class="code"><div>&#39;utf-8&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>DEFAULT_CONTENT_TYPE</td> 
          <td class="code"><div>&#39;text/html&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>DEFAULT_FILE_STORAGE</td> 
          <td class="code"><div>&#39;django.core.files.storage.FileSystemStorage&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>DEFAULT_FROM_EMAIL</td> 
          <td class="code"><div>&#39;webmaster@localhost&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>DEFAULT_INDEX_TABLESPACE</td> 
          <td class="code"><div>&#39;&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>DEFAULT_TABLESPACE</td> 
          <td class="code"><div>&#39;&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>DISALLOWED_USER_AGENTS</td> 
          <td class="code"><div>()</div></td> 
        </tr> 
      
        <tr> 
          <td>EMAIL_HOST</td> 
          <td class="code"><div>&#39;localhost&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>EMAIL_HOST_PASSWORD</td> 
          <td class="code"><div>&#39;********************&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>EMAIL_HOST_USER</td> 
          <td class="code"><div>&#39;&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>EMAIL_PORT</td> 
          <td class="code"><div>25</div></td> 
        </tr> 
      
        <tr> 
          <td>EMAIL_SUBJECT_PREFIX</td> 
          <td class="code"><div>&#39;[Django] &#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>EMAIL_USE_TLS</td> 
          <td class="code"><div>False</div></td> 
        </tr> 
      
        <tr> 
          <td>FILE_CHARSET</td> 
          <td class="code"><div>&#39;utf-8&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>FILE_UPLOAD_HANDLERS</td> 
          <td class="code"><div>(&#39;django.core.files.uploadhandler.MemoryFileUploadHandler&#39;,
 &#39;django.core.files.uploadhandler.TemporaryFileUploadHandler&#39;)</div></td> 
        </tr> 
      
        <tr> 
          <td>FILE_UPLOAD_MAX_MEMORY_SIZE</td> 
          <td class="code"><div>2621440</div></td> 
        </tr> 
      
        <tr> 
          <td>FILE_UPLOAD_PERMISSIONS</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>FILE_UPLOAD_TEMP_DIR</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>FIXTURE_DIRS</td> 
          <td class="code"><div>()</div></td> 
        </tr> 
      
        <tr> 
          <td>FORCE_SCRIPT_NAME</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>GOOGLE_ADMIN_EMAIL</td> 
          <td class="code"><div>&#39;********************&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>GOOGLE_ADMIN_PASSWORD</td> 
          <td class="code"><div>&#39;********************&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>GOOGLE_ADMIN_USERNAME</td> 
          <td class="code"><div>&#39;********************&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>GOOGLE_DOMAIN</td> 
          <td class="code"><div>&#39;********************&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>GOOGLE_IMAP_HOSTNAME</td> 
          <td class="code"><div>&#39;imap.gmail.com&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>GOOGLE_SMTP_HOSTNAME</td> 
          <td class="code"><div>&#39;smtp.gmail.com&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>GOOGLE_SMTP_PASSWORD</td> 
          <td class="code"><div>&#39;********************&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>GOOGLE_SMTP_PORT</td> 
          <td class="code"><div>587</div></td> 
        </tr> 
      
        <tr> 
          <td>GOOGLE_SMTP_TLS</td> 
          <td class="code"><div>True</div></td> 
        </tr> 
      
        <tr> 
          <td>GOOGLE_SMTP_USERNAME</td> 
          <td class="code"><div>&#39;********************&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>IGNORABLE_404_ENDS</td> 
          <td class="code"><div>(&#39;mail.pl&#39;, &#39;mailform.pl&#39;, &#39;mail.cgi&#39;, &#39;mailform.cgi&#39;, &#39;favicon.ico&#39;, &#39;.php&#39;)</div></td> 
        </tr> 
      
        <tr> 
          <td>IGNORABLE_404_STARTS</td> 
          <td class="code"><div>(&#39;/cgi-bin/&#39;, &#39;/_vti_bin&#39;, &#39;/_vti_inf&#39;)</div></td> 
        </tr> 
      
        <tr> 
          <td>INSTALLED_APPS</td> 
          <td class="code"><div>[&#39;django.contrib.admin&#39;,
 &#39;django.contrib.auth&#39;,
 &#39;django.contrib.contenttypes&#39;,
 &#39;django.contrib.sessions&#39;,
 &#39;django.contrib.sites&#39;,
 &#39;discovery.edisco&#39;]</div></td> 
        </tr> 
      
        <tr> 
          <td>INTERNAL_IPS</td> 
          <td class="code"><div>()</div></td> 
        </tr> 
      
        <tr> 
          <td>JING_PATH</td> 
          <td class="code"><div>&#39;/usr/bin/jing&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>LANGUAGES</td> 
          <td class="code"><div>((&#39;ar&#39;, &#39;Arabic&#39;),
 (&#39;bn&#39;, &#39;Bengali&#39;),
 (&#39;bg&#39;, &#39;Bulgarian&#39;),
 (&#39;ca&#39;, &#39;Catalan&#39;),
 (&#39;cs&#39;, &#39;Czech&#39;),
 (&#39;cy&#39;, &#39;Welsh&#39;),
 (&#39;da&#39;, &#39;Danish&#39;),
 (&#39;de&#39;, &#39;German&#39;),
 (&#39;el&#39;, &#39;Greek&#39;),
 (&#39;en&#39;, &#39;English&#39;),
 (&#39;es&#39;, &#39;Spanish&#39;),
 (&#39;et&#39;, &#39;Estonian&#39;),
 (&#39;es-ar&#39;, &#39;Argentinean Spanish&#39;),
 (&#39;eu&#39;, &#39;Basque&#39;),
 (&#39;fa&#39;, &#39;Persian&#39;),
 (&#39;fi&#39;, &#39;Finnish&#39;),
 (&#39;fr&#39;, &#39;French&#39;),
 (&#39;ga&#39;, &#39;Irish&#39;),
 (&#39;gl&#39;, &#39;Galician&#39;),
 (&#39;hu&#39;, &#39;Hungarian&#39;),
 (&#39;he&#39;, &#39;Hebrew&#39;),
 (&#39;hi&#39;, &#39;Hindi&#39;),
 (&#39;hr&#39;, &#39;Croatian&#39;),
 (&#39;is&#39;, &#39;Icelandic&#39;),
 (&#39;it&#39;, &#39;Italian&#39;),
 (&#39;ja&#39;, &#39;Japanese&#39;),
 (&#39;ka&#39;, &#39;Georgian&#39;),
 (&#39;ko&#39;, &#39;Korean&#39;),
 (&#39;km&#39;, &#39;Khmer&#39;),
 (&#39;kn&#39;, &#39;Kannada&#39;),
 (&#39;lv&#39;, &#39;Latvian&#39;),
 (&#39;lt&#39;, &#39;Lithuanian&#39;),
 (&#39;mk&#39;, &#39;Macedonian&#39;),
 (&#39;nl&#39;, &#39;Dutch&#39;),
 (&#39;no&#39;, &#39;Norwegian&#39;),
 (&#39;pl&#39;, &#39;Polish&#39;),
 (&#39;pt&#39;, &#39;Portuguese&#39;),
 (&#39;pt-br&#39;, &#39;Brazilian Portuguese&#39;),
 (&#39;ro&#39;, &#39;Romanian&#39;),
 (&#39;ru&#39;, &#39;Russian&#39;),
 (&#39;sk&#39;, &#39;Slovak&#39;),
 (&#39;sl&#39;, &#39;Slovenian&#39;),
 (&#39;sr&#39;, &#39;Serbian&#39;),
 (&#39;sv&#39;, &#39;Swedish&#39;),
 (&#39;ta&#39;, &#39;Tamil&#39;),
 (&#39;te&#39;, &#39;Telugu&#39;),
 (&#39;th&#39;, &#39;Thai&#39;),
 (&#39;tr&#39;, &#39;Turkish&#39;),
 (&#39;uk&#39;, &#39;Ukrainian&#39;),
 (&#39;zh-cn&#39;, &#39;Simplified Chinese&#39;),
 (&#39;zh-tw&#39;, &#39;Traditional Chinese&#39;))</div></td> 
        </tr> 
      
        <tr> 
          <td>LANGUAGES_BIDI</td> 
          <td class="code"><div>(&#39;he&#39;, &#39;ar&#39;, &#39;fa&#39;)</div></td> 
        </tr> 
      
        <tr> 
          <td>LANGUAGE_CODE</td> 
          <td class="code"><div>&#39;en-us&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>LANGUAGE_COOKIE_NAME</td> 
          <td class="code"><div>&#39;django_language&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>LDAP_BASE</td> 
          <td class="code"><div>&#39;********************&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>LDAP_SERVER</td> 
          <td class="code"><div>&#39;********************&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>LOCALE_PATHS</td> 
          <td class="code"><div>()</div></td> 
        </tr> 
      
        <tr> 
          <td>LOGIN_REDIRECT_URL</td> 
          <td class="code"><div>&#39;/accounts/profile/&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>LOGIN_URL</td> 
          <td class="code"><div>&#39;/accounts/login/&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>LOGOUT_URL</td> 
          <td class="code"><div>&#39;/accounts/logout/&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>MANAGERS</td> 
          <td class="code"><div>()</div></td> 
        </tr> 
      
        <tr> 
          <td>MEDIA_ROOT</td> 
          <td class="code"><div>&#39;&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>MEDIA_URL</td> 
          <td class="code"><div>&#39;&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>MIDDLEWARE_CLASSES</td> 
          <td class="code"><div>(&#39;django.middleware.common.CommonMiddleware&#39;,
 &#39;django.contrib.sessions.middleware.SessionMiddleware&#39;,
 &#39;django.contrib.auth.middleware.AuthenticationMiddleware&#39;,
 &#39;django.middleware.doc.XViewMiddleware&#39;)</div></td> 
        </tr> 
      
        <tr> 
          <td>MONTH_DAY_FORMAT</td> 
          <td class="code"><div>&#39;F j&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>PASSWORD_RESET_TIMEOUT_DAYS</td> 
          <td class="code"><div>&#39;********************&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>PREPEND_WWW</td> 
          <td class="code"><div>False</div></td> 
        </tr> 
      
        <tr> 
          <td>PROFANITIES_LIST</td> 
          <td class="code"><div>&#39;********************&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>ROOT_URLCONF</td> 
          <td class="code"><div>&#39;discovery.urls&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>SECRET_KEY</td> 
          <td class="code"><div>&#39;********************&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>SEND_BROKEN_LINK_EMAILS</td> 
          <td class="code"><div>False</div></td> 
        </tr> 
      
        <tr> 
          <td>SERVER_EMAIL</td> 
          <td class="code"><div>&#39;root@localhost&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>SESSION_COOKIE_AGE</td> 
          <td class="code"><div>1209600</div></td> 
        </tr> 
      
        <tr> 
          <td>SESSION_COOKIE_DOMAIN</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>SESSION_COOKIE_NAME</td> 
          <td class="code"><div>&#39;sessionid&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>SESSION_COOKIE_PATH</td> 
          <td class="code"><div>&#39;/&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>SESSION_COOKIE_SECURE</td> 
          <td class="code"><div>False</div></td> 
        </tr> 
      
        <tr> 
          <td>SESSION_ENGINE</td> 
          <td class="code"><div>&#39;django.contrib.sessions.backends.db&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>SESSION_EXPIRE_AT_BROWSER_CLOSE</td> 
          <td class="code"><div>False</div></td> 
        </tr> 
      
        <tr> 
          <td>SESSION_FILE_PATH</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>SESSION_SAVE_EVERY_REQUEST</td> 
          <td class="code"><div>False</div></td> 
        </tr> 
      
        <tr> 
          <td>SETTINGS_MODULE</td> 
          <td class="code"><div>&#39;discovery.settings&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>SITE_ID</td> 
          <td class="code"><div>1</div></td> 
        </tr> 
      
        <tr> 
          <td>TEMPLATE_CONTEXT_PROCESSORS</td> 
          <td class="code"><div>(&#39;django.core.context_processors.auth&#39;,
 &#39;django.core.context_processors.debug&#39;,
 &#39;django.core.context_processors.i18n&#39;,
 &#39;django.core.context_processors.media&#39;)</div></td> 
        </tr> 
      
        <tr> 
          <td>TEMPLATE_DEBUG</td> 
          <td class="code"><div>True</div></td> 
        </tr> 
      
        <tr> 
          <td>TEMPLATE_DIRS</td> 
          <td class="code"><div>(&#39;/usr/local/web/edisco/templates&#39;,)</div></td> 
        </tr> 
      
        <tr> 
          <td>TEMPLATE_LOADERS</td> 
          <td class="code"><div>(&#39;django.template.loaders.filesystem.load_template_source&#39;,
 &#39;django.template.loaders.app_directories.load_template_source&#39;)</div></td> 
        </tr> 
      
        <tr> 
          <td>TEMPLATE_STRING_IF_INVALID</td> 
          <td class="code"><div>&#39;&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>TEST_DATABASE_CHARSET</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>TEST_DATABASE_COLLATION</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>TEST_DATABASE_NAME</td> 
          <td class="code"><div>None</div></td> 
        </tr> 
      
        <tr> 
          <td>TEST_RUNNER</td> 
          <td class="code"><div>&#39;django.test.simple.run_tests&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>TIME_FORMAT</td> 
          <td class="code"><div>&#39;P&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>TIME_ZONE</td> 
          <td class="code"><div>&#39;PST8PDT&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>TRANSACTIONS_MANAGED</td> 
          <td class="code"><div>False</div></td> 
        </tr> 
      
        <tr> 
          <td>URL_VALIDATOR_USER_AGENT</td> 
          <td class="code"><div>&#39;Django/1.0.2 final (http://www.djangoproject.com)&#39;</div></td> 
        </tr> 
      
        <tr> 
          <td>USE_ETAGS</td> 
          <td class="code"><div>False</div></td> 
        </tr> 
      
        <tr> 
          <td>USE_I18N</td> 
          <td class="code"><div>False</div></td> 
        </tr> 
      
        <tr> 
          <td>YEAR_MONTH_FORMAT</td> 
          <td class="code"><div>&#39;F Y&#39;</div></td> 
        </tr> 
      
    </tbody> 
  </table> 
 
</div> 
 
<div id="explanation"> 
  <p> 
    You're seeing this error because you have <code>DEBUG = True</code> in your
    Django settings file. Change that to <code>False</code>, and Django will
    display a standard 500 page.
  </p> 
</div> 
</body> 
</html> 

comment:3 Changed 5 years ago by kmtracey

Egads, I'm guessing you did not preview what that looked like before submitting it? The debug page has a "switch-to-cut-and-paste" link that is useful for extracting just the traceback instead of the 90K/2,000 lines of the html that makes up the debug page. Using it to get just the traceback from that html:

 
Environment:
 
Request Method: GET
Request URL: http://lablnx04/accounts/login/
Django Version: 1.0.2 final
Python Version: 2.4.2
Installed Applications:
['django.contrib.admin',
 'django.contrib.auth',
 'django.contrib.contenttypes',
 'django.contrib.sessions',
 'django.contrib.sites',
 'discovery.edisco']
Installed Middleware:
('django.middleware.common.CommonMiddleware',
 'django.contrib.sessions.middleware.SessionMiddleware',
 'django.contrib.auth.middleware.AuthenticationMiddleware',
 'django.middleware.doc.XViewMiddleware')
 
 
Traceback:
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/core/handlers/base.py" in get_response
  86.                 response = callback(request, *callback_args, **callback_kwargs)
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/views/decorators/cache.py" in _wrapped_view_func
  44.         response = view_func(request, *args, **kwargs)
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/contrib/auth/views.py" in login
  33.     request.session.set_test_cookie()
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/contrib/sessions/backends/base.py" in set_test_cookie
  78.         self[self.TEST_COOKIE_NAME] = self.TEST_COOKIE_VALUE
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/contrib/sessions/backends/base.py" in __setitem__
  49.         self._session[key] = value
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/contrib/sessions/backends/base.py" in _get_session
  172.                 self._session_cache = self.load()
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/contrib/sessions/backends/db.py" in load
  16.                 expire_date__gt=datetime.datetime.now()
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/models/manager.py" in get
  93.         return self.get_query_set().get(*args, **kwargs)
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/models/query.py" in get
  304.         num = len(clone)
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/models/query.py" in __len__
  160.                 self._result_cache = list(self.iterator())
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/models/query.py" in iterator
  275.         for row in self.query.results_iter():
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/models/sql/query.py" in results_iter
  217.                     row = self.resolve_columns(row, fields)
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/backends/oracle/query.py" in resolve_columns
  52.                 values.append(self.convert_values(value, field))
File "/usr/local/lib64/python2.4/site-packages/Django-1.0.2_final-py2.4.egg/django/db/backends/oracle/query.py" in convert_values
  59.                 value = value.read()
 
Exception Type: UnicodeDecodeError at /accounts/login/
Exception Value: 'utf16' codec can't decode bytes in position 120-121: illegal UTF-16 surrogate

It's similar but not quite the same. Still have no clue what is going on in these error situations because I cannot recreate any problem on my own Oracle setup, and my knowedge of Oracle is just above zero (I was able to set it up for testing purposes, but I have not used it beyond that).

comment:4 follow-up: Changed 5 years ago by ikelly

What version of cx_Oracle is being used in these setups? My hope is that this is occurring with cx_Oracle 5.0, in which case the solution is easy: don't use that. cx_Oracle 5.0 has a known NCLOB decoding bug that makes it unusable for Django (I suppose we should document this). cx_Oracle trunk and the upcoming 5.0.1 release should be okay, as is the 4.4.1 release.

If you're not using cx_Oracle 5.0, let me know so we can investigate further.

comment:5 Changed 5 years ago by ikelly

(In [9709]) Refs #9935: Added a note in the documentation to the effect that Django currently requires a 4.X release of cx_Oracle.

comment:6 in reply to: ↑ 4 Changed 5 years ago by jamesli

Replying to ikelly:

What version of cx_Oracle is being used in these setups? My hope is that this is occurring with cx_Oracle 5.0, in which case the solution is easy: don't use that. cx_Oracle 5.0 has a known NCLOB decoding bug that makes it unusable for Django (I suppose we should document this). cx_Oracle trunk and the upcoming 5.0.1 release should be okay, as is the 4.4.1 release.

If you're not using cx_Oracle 5.0, let me know so we can investigate further.

Indeed, I was using version 5.0. Will try version 4.4.1 later.

comment:7 Changed 5 years ago by jamesli

I can confirm that cx_oracle 4.4.1 works fine (at least I didn't run into the problem I reported here).

comment:8 Changed 5 years ago by ikelly

  • Resolution set to wontfix
  • Status changed from new to closed

This seems to be caused by the cx_Oracle 5.0 NCLOB bug, which is severe enough that there's really nothing we can do about it now but wait for the next release.

comment:9 Changed 5 years ago by anonymous

  • milestone post-1.0 deleted

Milestone post-1.0 deleted

comment:10 follow-up: Changed 3 years ago by Goldan

  • Cc Goldan added

I can reproduce this bug in cx_Oracle 5.0.4 and Oracle9i Enterprise Edition Release 9.2.0.1.0 - Production.

Downgrading to cx_Oracle 4.4.1 solves the problem.

comment:11 in reply to: ↑ 10 Changed 3 years ago by ikelly

Replying to Goldan:

I can reproduce this bug in cx_Oracle 5.0.4 and Oracle9i Enterprise Edition Release 9.2.0.1.0 - Production.

Downgrading to cx_Oracle 4.4.1 solves the problem.

This ticket is ancient, and it's more likely that you're actually running into some other encoding bug than the one that was diagnosed here. Please create a new ticket for your report, and please include the traceback that you get as well.

Thanks,
Ian

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.