AttributeError 'module' object has no attribute 'version'
I am facing openstacksdk version problem.
2016-12-26 07:11:30.069 | +./stack.sh:main:1033 create_keystone_accounts
2016-12-26 07:11:30.074 | +lib/keystone:create_keystone_accounts:372 local admin_tenant
2016-12-26 07:11:30.081 | ++lib/keystone:create_keystone_accounts:373 openstack project show admin -f value -c id
2016-12-26 07:11:31.019 | Traceback (most recent call last):
2016-12-26 07:11:31.019 | File "/usr/local/bin/openstack", line 7, in
2016-12-26 07:11:31.019 | from openstackclient.shell import main
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstackclient/shell.py", line 32, in
2016-12-26 07:11:31.019 | from openstackclient.common import clientmanager
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstackclient/common/clientmanager.py", line 293, in
2016-12-26 07:11:31.019 | 'openstack.cli.base',
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstackclient/common/clientmanager.py", line 264, in get_plugin_modules
2016-12-26 07:11:31.019 | import(ep.module_name)
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstackclient/network/client.py", line 16, in
2016-12-26 07:11:31.019 | from openstack import connection
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstack/connection.py", line 68, in
2016-12-26 07:11:31.019 | from openstack import session as _session
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstack/session.py", line 29, in
2016-12-26 07:11:31.019 | DEFAULT_USER_AGENT = "openstacksdk/%s" % openstack.version
2016-12-26 07:11:31.019 | AttributeError: 'module' object has no attribute 'version'
2016-12-26 07:11:31.041 | +lib/keystone:create_keystone_accounts:373 admin_tenant=
2016-12-26 07:11:31.049 | +lib/keystone:create_keystone_accounts:1 exit_trap
2016-12-26 07:11:31.056 | +./stack.sh:exit_trap:474 local r=1
2016-12-26 07:11:31.064 | ++./stack.sh:exit_trap:475 jobs -p
2016-12-26 07:11:31.072 | +./stack.sh:exit_trap:475 jobs=
2016-12-26 07:11:31.079 | +./stack.sh:exit_trap:478 [[ -n '' ]]
2016-12-26 07:11:31.086 | +./stack.sh:exit_trap:484 kill_spinner
2016-12-26 07:11:31.092 | +./stack.sh:kill_spinner:370 '[' '!' -z '' ']'
2016-12-26 07:11:31.098 | +./stack.sh:exit_trap:486 [[ 1 -ne 0 ]]
2016-12-26 07:11:31.105 | +./stack.sh:exit_trap:487 echo 'Error on exit'
2016-12-26 07:11:31.105 | Error on exit
2016-12-26 07:11:31.110 | +./stack.sh:exit_trap:488 generate-subunit 1482733821 2470 fail
2016-12-26 07:11:31.479 | +./stack.sh:exit_trap:489 [[ -z /opt/stack/logs ]]
2016-12-26 07:11:31.487 | +./stack.sh:exit_trap:492 /opt/stack/devstack/tools/worlddump.py -d /opt/stack/logs
2016-12-26 07:11:31.895 | +./stack.sh:exit_trap:498 exit 1
stack@openstack:~/devstack$
I've tried to find the cause for this from past few days and I found that they updated OpenStack SDK version (UPDATE DEFAULT_USER_AGENT = "openstacksdk/%s" % openstack_version.__version__), But it's not working and throwing the same error.
Any help would be very much appreciable.
Thank you in advance.
openstack devstack
add a comment |
I am facing openstacksdk version problem.
2016-12-26 07:11:30.069 | +./stack.sh:main:1033 create_keystone_accounts
2016-12-26 07:11:30.074 | +lib/keystone:create_keystone_accounts:372 local admin_tenant
2016-12-26 07:11:30.081 | ++lib/keystone:create_keystone_accounts:373 openstack project show admin -f value -c id
2016-12-26 07:11:31.019 | Traceback (most recent call last):
2016-12-26 07:11:31.019 | File "/usr/local/bin/openstack", line 7, in
2016-12-26 07:11:31.019 | from openstackclient.shell import main
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstackclient/shell.py", line 32, in
2016-12-26 07:11:31.019 | from openstackclient.common import clientmanager
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstackclient/common/clientmanager.py", line 293, in
2016-12-26 07:11:31.019 | 'openstack.cli.base',
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstackclient/common/clientmanager.py", line 264, in get_plugin_modules
2016-12-26 07:11:31.019 | import(ep.module_name)
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstackclient/network/client.py", line 16, in
2016-12-26 07:11:31.019 | from openstack import connection
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstack/connection.py", line 68, in
2016-12-26 07:11:31.019 | from openstack import session as _session
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstack/session.py", line 29, in
2016-12-26 07:11:31.019 | DEFAULT_USER_AGENT = "openstacksdk/%s" % openstack.version
2016-12-26 07:11:31.019 | AttributeError: 'module' object has no attribute 'version'
2016-12-26 07:11:31.041 | +lib/keystone:create_keystone_accounts:373 admin_tenant=
2016-12-26 07:11:31.049 | +lib/keystone:create_keystone_accounts:1 exit_trap
2016-12-26 07:11:31.056 | +./stack.sh:exit_trap:474 local r=1
2016-12-26 07:11:31.064 | ++./stack.sh:exit_trap:475 jobs -p
2016-12-26 07:11:31.072 | +./stack.sh:exit_trap:475 jobs=
2016-12-26 07:11:31.079 | +./stack.sh:exit_trap:478 [[ -n '' ]]
2016-12-26 07:11:31.086 | +./stack.sh:exit_trap:484 kill_spinner
2016-12-26 07:11:31.092 | +./stack.sh:kill_spinner:370 '[' '!' -z '' ']'
2016-12-26 07:11:31.098 | +./stack.sh:exit_trap:486 [[ 1 -ne 0 ]]
2016-12-26 07:11:31.105 | +./stack.sh:exit_trap:487 echo 'Error on exit'
2016-12-26 07:11:31.105 | Error on exit
2016-12-26 07:11:31.110 | +./stack.sh:exit_trap:488 generate-subunit 1482733821 2470 fail
2016-12-26 07:11:31.479 | +./stack.sh:exit_trap:489 [[ -z /opt/stack/logs ]]
2016-12-26 07:11:31.487 | +./stack.sh:exit_trap:492 /opt/stack/devstack/tools/worlddump.py -d /opt/stack/logs
2016-12-26 07:11:31.895 | +./stack.sh:exit_trap:498 exit 1
stack@openstack:~/devstack$
I've tried to find the cause for this from past few days and I found that they updated OpenStack SDK version (UPDATE DEFAULT_USER_AGENT = "openstacksdk/%s" % openstack_version.__version__), But it's not working and throwing the same error.
Any help would be very much appreciable.
Thank you in advance.
openstack devstack
add a comment |
I am facing openstacksdk version problem.
2016-12-26 07:11:30.069 | +./stack.sh:main:1033 create_keystone_accounts
2016-12-26 07:11:30.074 | +lib/keystone:create_keystone_accounts:372 local admin_tenant
2016-12-26 07:11:30.081 | ++lib/keystone:create_keystone_accounts:373 openstack project show admin -f value -c id
2016-12-26 07:11:31.019 | Traceback (most recent call last):
2016-12-26 07:11:31.019 | File "/usr/local/bin/openstack", line 7, in
2016-12-26 07:11:31.019 | from openstackclient.shell import main
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstackclient/shell.py", line 32, in
2016-12-26 07:11:31.019 | from openstackclient.common import clientmanager
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstackclient/common/clientmanager.py", line 293, in
2016-12-26 07:11:31.019 | 'openstack.cli.base',
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstackclient/common/clientmanager.py", line 264, in get_plugin_modules
2016-12-26 07:11:31.019 | import(ep.module_name)
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstackclient/network/client.py", line 16, in
2016-12-26 07:11:31.019 | from openstack import connection
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstack/connection.py", line 68, in
2016-12-26 07:11:31.019 | from openstack import session as _session
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstack/session.py", line 29, in
2016-12-26 07:11:31.019 | DEFAULT_USER_AGENT = "openstacksdk/%s" % openstack.version
2016-12-26 07:11:31.019 | AttributeError: 'module' object has no attribute 'version'
2016-12-26 07:11:31.041 | +lib/keystone:create_keystone_accounts:373 admin_tenant=
2016-12-26 07:11:31.049 | +lib/keystone:create_keystone_accounts:1 exit_trap
2016-12-26 07:11:31.056 | +./stack.sh:exit_trap:474 local r=1
2016-12-26 07:11:31.064 | ++./stack.sh:exit_trap:475 jobs -p
2016-12-26 07:11:31.072 | +./stack.sh:exit_trap:475 jobs=
2016-12-26 07:11:31.079 | +./stack.sh:exit_trap:478 [[ -n '' ]]
2016-12-26 07:11:31.086 | +./stack.sh:exit_trap:484 kill_spinner
2016-12-26 07:11:31.092 | +./stack.sh:kill_spinner:370 '[' '!' -z '' ']'
2016-12-26 07:11:31.098 | +./stack.sh:exit_trap:486 [[ 1 -ne 0 ]]
2016-12-26 07:11:31.105 | +./stack.sh:exit_trap:487 echo 'Error on exit'
2016-12-26 07:11:31.105 | Error on exit
2016-12-26 07:11:31.110 | +./stack.sh:exit_trap:488 generate-subunit 1482733821 2470 fail
2016-12-26 07:11:31.479 | +./stack.sh:exit_trap:489 [[ -z /opt/stack/logs ]]
2016-12-26 07:11:31.487 | +./stack.sh:exit_trap:492 /opt/stack/devstack/tools/worlddump.py -d /opt/stack/logs
2016-12-26 07:11:31.895 | +./stack.sh:exit_trap:498 exit 1
stack@openstack:~/devstack$
I've tried to find the cause for this from past few days and I found that they updated OpenStack SDK version (UPDATE DEFAULT_USER_AGENT = "openstacksdk/%s" % openstack_version.__version__), But it's not working and throwing the same error.
Any help would be very much appreciable.
Thank you in advance.
openstack devstack
I am facing openstacksdk version problem.
2016-12-26 07:11:30.069 | +./stack.sh:main:1033 create_keystone_accounts
2016-12-26 07:11:30.074 | +lib/keystone:create_keystone_accounts:372 local admin_tenant
2016-12-26 07:11:30.081 | ++lib/keystone:create_keystone_accounts:373 openstack project show admin -f value -c id
2016-12-26 07:11:31.019 | Traceback (most recent call last):
2016-12-26 07:11:31.019 | File "/usr/local/bin/openstack", line 7, in
2016-12-26 07:11:31.019 | from openstackclient.shell import main
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstackclient/shell.py", line 32, in
2016-12-26 07:11:31.019 | from openstackclient.common import clientmanager
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstackclient/common/clientmanager.py", line 293, in
2016-12-26 07:11:31.019 | 'openstack.cli.base',
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstackclient/common/clientmanager.py", line 264, in get_plugin_modules
2016-12-26 07:11:31.019 | import(ep.module_name)
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstackclient/network/client.py", line 16, in
2016-12-26 07:11:31.019 | from openstack import connection
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstack/connection.py", line 68, in
2016-12-26 07:11:31.019 | from openstack import session as _session
2016-12-26 07:11:31.019 | File "/usr/local/lib/python2.7/dist-packages/openstack/session.py", line 29, in
2016-12-26 07:11:31.019 | DEFAULT_USER_AGENT = "openstacksdk/%s" % openstack.version
2016-12-26 07:11:31.019 | AttributeError: 'module' object has no attribute 'version'
2016-12-26 07:11:31.041 | +lib/keystone:create_keystone_accounts:373 admin_tenant=
2016-12-26 07:11:31.049 | +lib/keystone:create_keystone_accounts:1 exit_trap
2016-12-26 07:11:31.056 | +./stack.sh:exit_trap:474 local r=1
2016-12-26 07:11:31.064 | ++./stack.sh:exit_trap:475 jobs -p
2016-12-26 07:11:31.072 | +./stack.sh:exit_trap:475 jobs=
2016-12-26 07:11:31.079 | +./stack.sh:exit_trap:478 [[ -n '' ]]
2016-12-26 07:11:31.086 | +./stack.sh:exit_trap:484 kill_spinner
2016-12-26 07:11:31.092 | +./stack.sh:kill_spinner:370 '[' '!' -z '' ']'
2016-12-26 07:11:31.098 | +./stack.sh:exit_trap:486 [[ 1 -ne 0 ]]
2016-12-26 07:11:31.105 | +./stack.sh:exit_trap:487 echo 'Error on exit'
2016-12-26 07:11:31.105 | Error on exit
2016-12-26 07:11:31.110 | +./stack.sh:exit_trap:488 generate-subunit 1482733821 2470 fail
2016-12-26 07:11:31.479 | +./stack.sh:exit_trap:489 [[ -z /opt/stack/logs ]]
2016-12-26 07:11:31.487 | +./stack.sh:exit_trap:492 /opt/stack/devstack/tools/worlddump.py -d /opt/stack/logs
2016-12-26 07:11:31.895 | +./stack.sh:exit_trap:498 exit 1
stack@openstack:~/devstack$
I've tried to find the cause for this from past few days and I found that they updated OpenStack SDK version (UPDATE DEFAULT_USER_AGENT = "openstacksdk/%s" % openstack_version.__version__), But it's not working and throwing the same error.
Any help would be very much appreciable.
Thank you in advance.
openstack devstack
openstack devstack
edited Nov 20 '18 at 19:08
Federico Grandi
2,68521127
2,68521127
asked Jan 4 '17 at 5:27
Dheeraj Chitara
615
615
add a comment |
add a comment |
3 Answers
3
active
oldest
votes
Not 100% sure of what's causing this but I was able to get rid of this error by adding an explicit upgrade the python-openstackclient in the stack.sh script right after this section:
# Install the OpenStack client, needed for most setup commands
if use_library_from_git "python-openstackclient"; then
git_clone_by_name "python-openstackclient"
setup_dev_lib "python-openstackclient"
else
pip_install_gr python-openstackclient
fi
I added:
sudo pip install "python-openstackclient==<version_I_want>"
add a comment |
Edit the file trove-deshboard/requirements.txt
-e git://... => -e git+https://...
then edit requirements/upper-constraints.txt
openstacksdk===0.8.1 => openstacksdk===0.9.11 or 0.9.12
add a comment |
The official fix is listed here
https://review.openstack.org/#/c/325088/
I patched directly to /usr/local/lib/python2.7/dist-packages/openstack/
I was able to complete the ./stack.sh script without error
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f41456786%2fattributeerror-module-object-has-no-attribute-version%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
Not 100% sure of what's causing this but I was able to get rid of this error by adding an explicit upgrade the python-openstackclient in the stack.sh script right after this section:
# Install the OpenStack client, needed for most setup commands
if use_library_from_git "python-openstackclient"; then
git_clone_by_name "python-openstackclient"
setup_dev_lib "python-openstackclient"
else
pip_install_gr python-openstackclient
fi
I added:
sudo pip install "python-openstackclient==<version_I_want>"
add a comment |
Not 100% sure of what's causing this but I was able to get rid of this error by adding an explicit upgrade the python-openstackclient in the stack.sh script right after this section:
# Install the OpenStack client, needed for most setup commands
if use_library_from_git "python-openstackclient"; then
git_clone_by_name "python-openstackclient"
setup_dev_lib "python-openstackclient"
else
pip_install_gr python-openstackclient
fi
I added:
sudo pip install "python-openstackclient==<version_I_want>"
add a comment |
Not 100% sure of what's causing this but I was able to get rid of this error by adding an explicit upgrade the python-openstackclient in the stack.sh script right after this section:
# Install the OpenStack client, needed for most setup commands
if use_library_from_git "python-openstackclient"; then
git_clone_by_name "python-openstackclient"
setup_dev_lib "python-openstackclient"
else
pip_install_gr python-openstackclient
fi
I added:
sudo pip install "python-openstackclient==<version_I_want>"
Not 100% sure of what's causing this but I was able to get rid of this error by adding an explicit upgrade the python-openstackclient in the stack.sh script right after this section:
# Install the OpenStack client, needed for most setup commands
if use_library_from_git "python-openstackclient"; then
git_clone_by_name "python-openstackclient"
setup_dev_lib "python-openstackclient"
else
pip_install_gr python-openstackclient
fi
I added:
sudo pip install "python-openstackclient==<version_I_want>"
answered Jan 18 '17 at 0:31
user3912895
1
1
add a comment |
add a comment |
Edit the file trove-deshboard/requirements.txt
-e git://... => -e git+https://...
then edit requirements/upper-constraints.txt
openstacksdk===0.8.1 => openstacksdk===0.9.11 or 0.9.12
add a comment |
Edit the file trove-deshboard/requirements.txt
-e git://... => -e git+https://...
then edit requirements/upper-constraints.txt
openstacksdk===0.8.1 => openstacksdk===0.9.11 or 0.9.12
add a comment |
Edit the file trove-deshboard/requirements.txt
-e git://... => -e git+https://...
then edit requirements/upper-constraints.txt
openstacksdk===0.8.1 => openstacksdk===0.9.11 or 0.9.12
Edit the file trove-deshboard/requirements.txt
-e git://... => -e git+https://...
then edit requirements/upper-constraints.txt
openstacksdk===0.8.1 => openstacksdk===0.9.11 or 0.9.12
answered Jan 25 '17 at 11:58
Dheeraj Chitara
615
615
add a comment |
add a comment |
The official fix is listed here
https://review.openstack.org/#/c/325088/
I patched directly to /usr/local/lib/python2.7/dist-packages/openstack/
I was able to complete the ./stack.sh script without error
add a comment |
The official fix is listed here
https://review.openstack.org/#/c/325088/
I patched directly to /usr/local/lib/python2.7/dist-packages/openstack/
I was able to complete the ./stack.sh script without error
add a comment |
The official fix is listed here
https://review.openstack.org/#/c/325088/
I patched directly to /usr/local/lib/python2.7/dist-packages/openstack/
I was able to complete the ./stack.sh script without error
The official fix is listed here
https://review.openstack.org/#/c/325088/
I patched directly to /usr/local/lib/python2.7/dist-packages/openstack/
I was able to complete the ./stack.sh script without error
answered Mar 9 '17 at 2:35
r_cc_c
1
1
add a comment |
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f41456786%2fattributeerror-module-object-has-no-attribute-version%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown