ocata heat devstack plugin checking out heat master

Bug #1738372 reported by lxy-em30
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
OpenStack Heat
New
Undecided
Unassigned
OpenStack Identity (keystone)
Invalid
Undecided
Unassigned

Bug Description

When I run the following command:
su -s /bin/sh -c "keystone-manage db_sync" keystone

One exception raised:
AttributeError: 'module' object has no attribute 'DocumentedRuleDefault'

I don't know what is? But I have searched on the internet, and this may be caused by the python Env. I want to know the exactly version python packages and version. Thanks a lot.

This bug tracker is for errors with the documentation, use the following as a template and remove or add fields as you see fit. Convert [ ] into [x] to check boxes:

- [ ] This doc is inaccurate in this way: ______
- [ ] This is a doc addition request.
- [ ] I have a fix to the document that I can paste below including example: input and output.

If you have a troubleshooting or support issue, use the following resources:

 - Ask OpenStack: http://ask.openstack.org
 - The mailing list: http://lists.openstack.org
 - IRC: 'openstack' channel on Freenode

-----------------------------------
Release: 12.0.1.dev6 on 2017-11-16 21:02
SHA: d0721d7cf4dc808946a7016b0ca2830c8850d5d9
Source: https://git.openstack.org/cgit/openstack/keystone/tree/doc/source/install/keystone-install-ubuntu.rst
URL: https://docs.openstack.org/keystone/pike/install/keystone-install-ubuntu.html

Tags: doc
Revision history for this message
Lance Bragstad (lbragstad) wrote :

It looks like you're missing or have an old version of oslo.policy. The DocumentedRuleDefault object was added to oslo.policy in version 1.29.

I recommend retrying you're installation once you have an updated version of oslo.policy.

Changed in keystone:
status: New → Invalid
Revision history for this message
அருண் குமார் - Arun Kumar (thangamani-arun) wrote :

This error still exists in oslo.policy v1.18.0 while building devstack stable/ocata on ubuntu 16.04.3

Here is the error:

2018-02-04 15:56:11.463 | ++/opt/stack/heat/devstack/lib/heat:init_heat:263 /usr/local/bin/heat-manage db_sync
2018-02-04 15:56:12.693 | Traceback (most recent call last):
2018-02-04 15:56:12.693 | File "/usr/local/bin/heat-manage", line 6, in <module>
2018-02-04 15:56:12.693 | from heat.cmd.manage import main
2018-02-04 15:56:12.693 | File "/home/stack/heat/heat/cmd/manage.py", line 24, in <module>
2018-02-04 15:56:12.693 | from heat.common import context
2018-02-04 15:56:12.693 | File "/home/stack/heat/heat/common/context.py", line 31, in <module>
2018-02-04 15:56:12.693 | from heat.common import policy
2018-02-04 15:56:12.694 | File "/home/stack/heat/heat/common/policy.py", line 28, in <module>
2018-02-04 15:56:12.694 | from heat import policies
2018-02-04 15:56:12.694 | File "/home/stack/heat/heat/policies/__init__.py", line 16, in <module>
2018-02-04 15:56:12.694 | from heat.policies import actions
2018-02-04 15:56:12.694 | File "/home/stack/heat/heat/policies/actions.py", line 20, in <module>
2018-02-04 15:56:12.694 | policy.DocumentedRuleDefault(
2018-02-04 15:56:12.694 | AttributeError: 'module' object has no attribute 'DocumentedRuleDefault'
2018-02-04 15:56:12.750 | +/opt/stack/heat/devstack/lib/heat:init_heat:1 exit_trap
2018-02-04 15:56:12.759 | +./stack.sh:exit_trap:494 local r=1
2018-02-04 15:56:12.769 | ++./stack.sh:exit_trap:495 jobs -p
2018-02-04 15:56:12.778 | +./stack.sh:exit_trap:495 jobs=
2018-02-04 15:56:12.785 | +./stack.sh:exit_trap:498 [[ -n '' ]]
2018-02-04 15:56:12.794 | +./stack.sh:exit_trap:504 kill_spinner
2018-02-04 15:56:12.803 | +./stack.sh:kill_spinner:390 '[' '!' -z '' ']'
2018-02-04 15:56:12.811 | +./stack.sh:exit_trap:506 [[ 1 -ne 0 ]]
2018-02-04 15:56:12.819 | +./stack.sh:exit_trap:507 echo 'Error on exit'
2018-02-04 15:56:12.819 | Error on exit
2018-02-04 15:56:12.826 | +./stack.sh:exit_trap:508 generate-subunit 1517757635 2137 fail
2018-02-04 15:56:13.489 | +./stack.sh:exit_trap:509 [[ -z /opt/stack/logs ]]
2018-02-04 15:56:13.497 | +./stack.sh:exit_trap:512 /home/stack/devstack/tools/worlddump.py -d /opt/stack/logs
2018-02-04 15:56:15.539 | +./stack.sh:exit_trap:518 exit 1

Eventhough I did upgrade oslo.policy to v1.33.1, still I'm getting error becuase /opt/stack/requirements/upper-constraints.txt file got oslo.policy===1.18.0, So its re-installing oslo.ploicy to v1.18.0 from v1.33.1

I tried updating file /opt/stack/requirements/upper-constraints.txt with oslo.policy===1.33.1 and ran ./stack.sh, still getting the same error.

Changed in keystone:
status: Invalid → Confirmed
Revision history for this message
Gage Hugo (gagehugo) wrote :

2018-02-04 15:56:11.463 | ++/opt/stack/heat/devstack/lib/heat:init_heat:263 /usr/local/bin/heat-manage db_sync

Is this something with heat/oslo.policy then?

Revision history for this message
அருண் குமார் - Arun Kumar (thangamani-arun) wrote :

yes @Gage Hugo

Revision history for this message
அருண் குமார் - Arun Kumar (thangamani-arun) wrote :

Ubuntu 16.04.3 LTS, the latest supported version of oslo.polcy is 1.18.0.

stack@arunx:~/devstack$ pip show oslo.policy
Name: oslo.policy
Version: 1.18.0
Summary: Oslo Policy library
Home-page: http://docs.openstack.org/developer/oslo.policy/
Author: OpenStack
Author-email: <email address hidden>
License: UNKNOWN
Location: /usr/local/lib/python2.7/dist-packages
Requires: six, requests, stevedore, oslo.serialization, PyYAML, oslo.config, oslo.i18n

Revision history for this message
அருண் குமார் - Arun Kumar (thangamani-arun) wrote :

This issue is preventing HEAT service is not being able to build for devstack-stable/ocata release. Hence only

Revision history for this message
Gage Hugo (gagehugo) wrote :

Had an engineer run into this while using ocata devstack + heat, will look into further.

Revision history for this message
Gage Hugo (gagehugo) wrote :

I was able to duplicate this, it seems like there may be an issue with the heat devstack plugin, when running devstack (stable/ocata) it originally checks out stable/ocata heat, but once it hits the devstack plugin it will checkout master heat, and then hit:

2018-02-04 15:56:12.694 | from heat.policies import actions
2018-02-04 15:56:12.694 | File "/home/stack/heat/heat/policies/actions.py", line 20, in <module>
2018-02-04 15:56:12.694 | policy.DocumentedRuleDefault(
2018-02-04 15:56:12.694 | AttributeError: 'module' object has no attribute 'DocumentedRuleDefault'

https://github.com/openstack/heat/blob/master/heat/policies/actions.py#L20

Looks like the policies modules were added after ocata:

https://github.com/openstack/heat/tree/stable/ocata/heat/policies/actions.py

Changed in keystone:
status: Confirmed → Invalid
summary: - Install and configure in keystone
+ ocata devstack checking out Heat master
summary: - ocata devstack checking out Heat master
+ ocata heat devstack plugin checking out heat master
Rico Lin (rico-lin)
Changed in heat:
milestone: none → no-priority-tag-bugs
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.