Created a stack in single node devstack, containing resources- one network, two subnets in it, one instance of cirros-0.3.1-x86_64-uec in subnet2. Stack is created successfully but not able to delete it in first attempt. output of deletion of stack and heat event-list command are shown below-
1)deleted the stack "stack3"-
$heat stack-delete stack3
+--------------------------------------+------------+--------------------+----------------------+
| id | stack_name | stack_status | creation_time |
+--------------------------------------+------------+--------------------+----------------------+
| 53750cd6-7744-4bc8-9078-4116fe30a170 | stack3 | DELETE_IN_PROGRESS | 2014-06-05T11:22:10Z |
+--------------------------------------+------------+--------------------+----------------------+
$heat stack-list
+--------------------------------------+------------+---------------+----------------------+
| id | stack_name | stack_status | creation_time |
+--------------------------------------+------------+---------------+----------------------+
| 53750cd6-7744-4bc8-9078-4116fe30a170 | stack3 | DELETE_FAILED | 2014-06-05T11:22:10Z |
+--------------------------------------+------------+---------------+----------------------+
2) deletion gets failed and output of heat event-list-
$ heat event-list stack3
+-----------------+--------------------------------------+-----------------------------------------------------------+--------------------+----------------------+
| resource_name | id | resource_status_reason | resource_status | event_time |
+-----------------+--------------------------------------+-----------------------------------------------------------+--------------------+----------------------+
| instance0 | 62379d9a-333a-48da-a0ee-7a8afb83d82e | state changed | DELETE_IN_PROGRESS | 2014-06-05T12:06:21Z |
| instance0 | 7630c591-131c-4ecc-b0bc-55c25171782f | state changed | CREATE_COMPLETE | 2014-06-05T11:22:50Z |
| instance0 | 90ec2e1a-4527-4ca7-becb-2ea8688ccfda | AttributeError: 'NotFound' object has no attribute 'code' | DELETE_FAILED | 2014-06-05T12:06:28Z |
| instance0 | d9a930a5-e59a-4329-a306-76ec25049390 | state changed | CREATE_IN_PROGRESS | 2014-06-05T11:22:16Z |
| instance0_port0 | 8a371b2c-ece1-40ff-bfcc-dc8c696ee5b5 | state changed | CREATE_COMPLETE | 2014-06-05T11:22:14Z |
| instance0_port0 | 96c9f4d4-b2f2-44c5-83bc-5a95f6983753 | state changed | CREATE_IN_PROGRESS | 2014-06-05T11:22:12Z |
| network | 03aaa2a8-4a19-4b15-b400-91623edd4c8d | state changed | CREATE_COMPLETE | 2014-06-05T11:22:10Z |
| network | a6adfd92-c725-401b-a52d-3cb7402d23f9 | state changed | CREATE_IN_PROGRESS | 2014-06-05T11:22:10Z |
| subnet1 | 39c44700-d368-4d17-a495-7086fb745d56 | state changed | CREATE_IN_PROGRESS | 2014-06-05T11:22:11Z |
| subnet1 | 828d593f-5a8d-491d-9c8f-9abf9e0a19e8 | state changed | CREATE_COMPLETE | 2014-06-05T11:22:12Z |
| subnet2 | 4824587f-2140-4992-87d3-d1f4d8481afa | state changed | CREATE_COMPLETE | 2014-06-05T11:22:12Z |
| subnet2 | b400417e-0a90-48f3-ab02-a3e573143daa | state changed | CREATE_IN_PROGRESS | 2014-06-05T11:22:11Z |
+-----------------+--------------------------------------+-----------------------------------------------------------+--------------------+----------------------+
Now if you want to delete it, we need to execute the stack-delete command again, then it deletes the stack.
It should be deleted in first attempt.
Vaibhav i tries it twice, but i am not able to reproduce the Bug