← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1287948] [NEW] Orchestration: AttributeError: 'str' object has no attribute 'year'

 

Public bug reported:

I'm running a current devstack. If I have an existing stack, the
Orchestration/Stacks page returns an error 500.

[Tue Mar 04 14:04:19.322198 2014] [:error] [pid 27147] Error while rendering table rows.
[Tue Mar 04 14:04:19.322640 2014] [:error] [pid 27147] Traceback (most recent call last):
[Tue Mar 04 14:04:19.322804 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 1559, in get_rows
[Tue Mar 04 14:04:19.322933 2014] [:error] [pid 27147]     row = self._meta.row_class(self, datum)
[Tue Mar 04 14:04:19.323066 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 476, in __init__
[Tue Mar 04 14:04:19.323193 2014] [:error] [pid 27147]     self.load_cells()
[Tue Mar 04 14:04:19.323316 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 502, in load_cells
[Tue Mar 04 14:04:19.323474 2014] [:error] [pid 27147]     cell = table._meta.cell_class(datum, column, self)
[Tue Mar 04 14:04:19.323595 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 597, in __init__
[Tue Mar 04 14:04:19.323721 2014] [:error] [pid 27147]     self.data = self.get_data(datum, column, row)
[Tue Mar 04 14:04:19.323864 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 635, in get_data
[Tue Mar 04 14:04:19.323994 2014] [:error] [pid 27147]     data = column.get_data(datum)
[Tue Mar 04 14:04:19.324116 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 350, in get_data
[Tue Mar 04 14:04:19.324240 2014] [:error] [pid 27147]     data = filter_func(data)
[Tue Mar 04 14:04:19.324398 2014] [:error] [pid 27147]   File "/usr/lib/python2.7/site-packages/django/utils/timesince.py", line 32, in timesince
[Tue Mar 04 14:04:19.324517 2014] [:error] [pid 27147]     d = datetime.datetime(d.year, d.month, d.day)
[Tue Mar 04 14:04:19.324639 2014] [:error] [pid 27147] AttributeError: 'str' object has no attribute 'year'
[Tue Mar 04 14:04:19.368743 2014] [:error] [pid 27147] Internal Server Error: /project/stacks/

Steps to reproduce:
1. Log in as a regular user and go to the Orchestration -> Stacks page
2. Launch a new stack using an existing template, e.g. https://github.com/openstack/heat-templates/blob/master/hot/hello_world.yaml
3. Fill in the information and click Launch
4. The above error is now displayed on  the index page

Adding the debug info from the heat client call:

{"stacks": [{"description": "Hello world HOT template that just defines
a single compute instance. Contains just base features to verify base
HOT support.\\n", "links": [{"href":
"http://192.168.100.190:8004/v1/3ba0ed232e004fbe9a47721ec5bd9bc6/stacks/heattest
/82f1dfef-c3e9-44c3-b62b-e7cc2d325d6e", "rel": "self"}],
"stack_status_reason": "Stack CREATE started", "stack_name": "heattest",
"creation_time": "2014-03-04T14:10:04Z", "updated_time": null,
"stack_status": "CREATE_IN_PROGRESS", "id": "82f1dfef-c3e9-44c3-b62b-
e7cc2d325d6e"}]}

** Affects: horizon
     Importance: Undecided
         Status: New

** Description changed:

  I'm running a current devstack. If I have an existing stack, the
  Orchestration/Stacks page returns an error 500.
  
  [Tue Mar 04 14:04:19.322198 2014] [:error] [pid 27147] Error while rendering table rows.
  [Tue Mar 04 14:04:19.322640 2014] [:error] [pid 27147] Traceback (most recent call last):
  [Tue Mar 04 14:04:19.322804 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 1559, in get_rows
  [Tue Mar 04 14:04:19.322933 2014] [:error] [pid 27147]     row = self._meta.row_class(self, datum)
  [Tue Mar 04 14:04:19.323066 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 476, in __init__
  [Tue Mar 04 14:04:19.323193 2014] [:error] [pid 27147]     self.load_cells()
  [Tue Mar 04 14:04:19.323316 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 502, in load_cells
  [Tue Mar 04 14:04:19.323474 2014] [:error] [pid 27147]     cell = table._meta.cell_class(datum, column, self)
  [Tue Mar 04 14:04:19.323595 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 597, in __init__
  [Tue Mar 04 14:04:19.323721 2014] [:error] [pid 27147]     self.data = self.get_data(datum, column, row)
  [Tue Mar 04 14:04:19.323864 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 635, in get_data
  [Tue Mar 04 14:04:19.323994 2014] [:error] [pid 27147]     data = column.get_data(datum)
  [Tue Mar 04 14:04:19.324116 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 350, in get_data
  [Tue Mar 04 14:04:19.324240 2014] [:error] [pid 27147]     data = filter_func(data)
  [Tue Mar 04 14:04:19.324398 2014] [:error] [pid 27147]   File "/usr/lib/python2.7/site-packages/django/utils/timesince.py", line 32, in timesince
  [Tue Mar 04 14:04:19.324517 2014] [:error] [pid 27147]     d = datetime.datetime(d.year, d.month, d.day)
  [Tue Mar 04 14:04:19.324639 2014] [:error] [pid 27147] AttributeError: 'str' object has no attribute 'year'
  [Tue Mar 04 14:04:19.368743 2014] [:error] [pid 27147] Internal Server Error: /project/stacks/
  
- 
  Steps to reproduce:
  1. Log in as a regular user and go to the Orchestration -> Stacks page
  2. Launch a new stack using an existing template, e.g. https://github.com/openstack/heat-templates/blob/master/hot/hello_world.yaml
  3. Fill in the information and click Launch
  4. The above error is now displayed on  the index page
+ 
+ Adding the debug info from the heat client call:
+ 
+ {"stacks": [{"description": "Hello world HOT template that just defines
+ a single compute instance. Contains just base features to verify base
+ HOT support.\\n", "links": [{"href":
+ "http://192.168.100.190:8004/v1/3ba0ed232e004fbe9a47721ec5bd9bc6/stacks/heattest
+ /82f1dfef-c3e9-44c3-b62b-e7cc2d325d6e", "rel": "self"}],
+ "stack_status_reason": "Stack CREATE started", "stack_name": "heattest",
+ "creation_time": "2014-03-04T14:10:04Z", "updated_time": null,
+ "stack_status": "CREATE_IN_PROGRESS", "id": "82f1dfef-c3e9-44c3-b62b-
+ e7cc2d325d6e"}]}

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Dashboard (Horizon).
https://bugs.launchpad.net/bugs/1287948

Title:
  Orchestration: AttributeError: 'str' object has no attribute 'year'

Status in OpenStack Dashboard (Horizon):
  New

Bug description:
  I'm running a current devstack. If I have an existing stack, the
  Orchestration/Stacks page returns an error 500.

  [Tue Mar 04 14:04:19.322198 2014] [:error] [pid 27147] Error while rendering table rows.
  [Tue Mar 04 14:04:19.322640 2014] [:error] [pid 27147] Traceback (most recent call last):
  [Tue Mar 04 14:04:19.322804 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 1559, in get_rows
  [Tue Mar 04 14:04:19.322933 2014] [:error] [pid 27147]     row = self._meta.row_class(self, datum)
  [Tue Mar 04 14:04:19.323066 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 476, in __init__
  [Tue Mar 04 14:04:19.323193 2014] [:error] [pid 27147]     self.load_cells()
  [Tue Mar 04 14:04:19.323316 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 502, in load_cells
  [Tue Mar 04 14:04:19.323474 2014] [:error] [pid 27147]     cell = table._meta.cell_class(datum, column, self)
  [Tue Mar 04 14:04:19.323595 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 597, in __init__
  [Tue Mar 04 14:04:19.323721 2014] [:error] [pid 27147]     self.data = self.get_data(datum, column, row)
  [Tue Mar 04 14:04:19.323864 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 635, in get_data
  [Tue Mar 04 14:04:19.323994 2014] [:error] [pid 27147]     data = column.get_data(datum)
  [Tue Mar 04 14:04:19.324116 2014] [:error] [pid 27147]   File "/opt/stack/horizon/openstack_dashboard/wsgi/../../horizon/tables/base.py", line 350, in get_data
  [Tue Mar 04 14:04:19.324240 2014] [:error] [pid 27147]     data = filter_func(data)
  [Tue Mar 04 14:04:19.324398 2014] [:error] [pid 27147]   File "/usr/lib/python2.7/site-packages/django/utils/timesince.py", line 32, in timesince
  [Tue Mar 04 14:04:19.324517 2014] [:error] [pid 27147]     d = datetime.datetime(d.year, d.month, d.day)
  [Tue Mar 04 14:04:19.324639 2014] [:error] [pid 27147] AttributeError: 'str' object has no attribute 'year'
  [Tue Mar 04 14:04:19.368743 2014] [:error] [pid 27147] Internal Server Error: /project/stacks/

  Steps to reproduce:
  1. Log in as a regular user and go to the Orchestration -> Stacks page
  2. Launch a new stack using an existing template, e.g. https://github.com/openstack/heat-templates/blob/master/hot/hello_world.yaml
  3. Fill in the information and click Launch
  4. The above error is now displayed on  the index page

  Adding the debug info from the heat client call:

  {"stacks": [{"description": "Hello world HOT template that just
  defines a single compute instance. Contains just base features to
  verify base HOT support.\\n", "links": [{"href":
  "http://192.168.100.190:8004/v1/3ba0ed232e004fbe9a47721ec5bd9bc6/stacks/heattest
  /82f1dfef-c3e9-44c3-b62b-e7cc2d325d6e", "rel": "self"}],
  "stack_status_reason": "Stack CREATE started", "stack_name":
  "heattest", "creation_time": "2014-03-04T14:10:04Z", "updated_time":
  null, "stack_status": "CREATE_IN_PROGRESS", "id": "82f1dfef-c3e9-44c3
  -b62b-e7cc2d325d6e"}]}

To manage notifications about this bug go to:
https://bugs.launchpad.net/horizon/+bug/1287948/+subscriptions


Follow ups

References