Projet

Général

Profil

Actions

Anomalie #1040

fermé

DASHBOARD CRASH : on general info

Ajouté par Yann Le Jeune il y a plus de 11 ans. Mis à jour il y a environ 11 ans.

Statut:
Résolu
Priorité:
Haut
Assigné à:
Catégorie:
-
Version cible:
Début:
12 octobre 2012
Echéance:
% réalisé:

0%

Temps estimé:
Élément(s):
Difficulté:

Description

The general Info crash :


AttributeError at /test/dashboard_main/

'NoneType' object has no attribute 'year'

Request Method: GET

Request URL: http://ishtar.proxience.com/test/dashboard_main/

Django Version: 1.2.3

Exception Type: AttributeError

Exception Value:

'NoneType' object has no attribute 'year'

Exception Location: /var/local/ishtar-test/ishtar/ishtar_base/models.py in get_years, line 1710

Python Executable: /usr/bin/python

Python Version: 2.6.6

Python Path: ['/usr/lib/python2.6', '/usr/lib/python2.6/plat-linux2', '/usr/lib/python2.6/lib-tk', '/usr/lib/python2.6/lib-old', '/usr/lib/python2.6/lib-dynload', '/usr/local/lib/python2.6/dist-packages', '/usr/lib/python2.6/dist-packages', '/usr/lib/python2.6/dist-packages/PIL', '/usr/lib/pymodules/python2.6', '/var/local/ishtar-test/', '/var/local/ishtar-test/ishtar/../xhtml2odt', '/var/local/ishtar-test/ishtar/../xhtml2odt']

Server time: ven, 12 Oct 2012 16:55:12 +0200

Traceback Switch to copy-and-paste view

/usr/lib/pymodules/python2.6/django/core/handlers/base.py in get_response

    response = callback(request, *callback_args, **callback_kwargs) ...

▶ Local vars

/var/local/ishtar-test/ishtar/ishtar_base/views.py in action

    return globals_dct[action_slug](request, dct, obj_id, *args, **kwargs) ...

▶ Local vars

/var/local/ishtar-test/ishtar/ishtar_base/views.py in dashboard_main

    (_(u"Context records"), models.Dashboard(models.ContextRecord)), ...

▶ Local vars

/var/local/ishtar-test/ishtar/ishtar_base/models.py in __init__

    self.years = model.get_years() ...

▶ Local vars

/var/local/ishtar-test/ishtar/ishtar_base/models.py in get_years

    yr = res['operation__start_date'].year ...

▶ Local vars 

Mis à jour par Yann Le Jeune il y a plus de 11 ans

Bug still present on the new version of django.

Mis à jour par Yann Le Jeune il y a environ 11 ans

Now OK for general info but isn't for FILE dashboard :

IndexError at /dashboard_file/

list index out of range

Request Method: GET

Request URL: http://192.168.100.204/dashboard_file/

Django Version: 1.4.5

Exception Type: IndexError

Exception Value:

list index out of range

Exception Location: /usr/lib/python2.7/dist-packages/django/db/models/query.py in getitem, line 190

Python Executable: /usr/bin/python

Python Version: 2.7.3

Python Path:

['/usr/lib/python2.7',

'/usr/lib/python2.7/plat-linux2',

'/usr/lib/python2.7/lib-tk',

'/usr/lib/python2.7/lib-old',

'/usr/lib/python2.7/lib-dynload',

'/usr/local/lib/python2.7/dist-packages',

'/usr/lib/python2.7/dist-packages',

'/usr/lib/python2.7/dist-packages/PIL',

'/usr/lib/pymodules/python2.7',

'/srv/ishtar/',

'/usr/local/lib/',

'/usr/local/lib/']

Server time: jeu, 14 Mar 2013 00:53:54 +0100

Traceback Switch to copy-and-paste view

/usr/lib/python2.7/dist-packages/django/core/handlers/base.py in get_response


                            response = callback(request, *callback_args, **callback_kwargs)


    ...

▶ Local vars

/srv/ishtar/archaeological_files/views.py in dashboard_file


        dct = {'dashboard': models.FileDashboard()}


    ...

▶ Local vars

/srv/ishtar/archaeological_files/models.py in __init__


                if by_year_operationnal[idx]['date'] != dct['date'] or\


    ...

▶ Local vars

/usr/lib/python2.7/dist-packages/django/db/models/query.py in __getitem__


                return self._result_cache[k]


    ...

▶ Local vars 

Mis à jour par Étienne Loks il y a environ 11 ans

  • Statut changé de Nouveau à Résolu
Actions

Formats disponibles : Atom PDF