Bug 1380536

Summary: awscli - ImportError: No module named six.moves
Product: [Fedora] Fedora EPEL Reporter: andyboutte
Component: awscliAssignee: Fabio Alessandro Locati <fale>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: unspecified    
Version: epel7CC: andyboutte, fale
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: awscli-1.11.0-1.el7 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-10-21 15:52:17 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Attachments:
Description Flags
This Vagrantfile can be used to recreate the environment I am working in. none

Description andyboutte 2016-09-29 23:01:11 UTC
Created attachment 1206061 [details]
This Vagrantfile can be used to recreate the environment I am working in.

Description of problem:

After install the awscli I receive the following error message:

ImportError: No module named six.moves


Version-Release number of selected component (if applicable):

I am using CentOS 7 in vagrant:

$ vagrant box list
centos/7 (virtualbox, 1606.01)

[root@radar-kitchen-development yum.repos.d]# rpm -qa |grep aws
awscli-1.10.62-1.el7.noarch

[root@radar-kitchen-development yum.repos.d]# uname -a
Linux radar-kitchen-development.itsreaning.com 3.10.0-327.22.2.el7.x86_64 #1 SMP Thu Jun 23 17:05:11 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux


How reproducible:

Every time.


Steps to Reproduce:
1. Stand up cento7 vagrant (Vagrantfile provided)
2. yum install -y epel-release
3. yum install -y awscli
4. aws --help

Actual results:

[root@localhost vagrant]# aws --help
Traceback (most recent call last):
  File "/bin/aws", line 19, in <module>
    import awscli.clidriver
  File "/usr/lib/python2.7/site-packages/awscli/clidriver.py", line 17, in <module>
    import botocore.session
  File "/usr/lib/python2.7/site-packages/botocore/session.py", line 25, in <module>
    import botocore.configloader
  File "/usr/lib/python2.7/site-packages/botocore/configloader.py", line 18, in <module>
    from six.moves import configparser
ImportError: No module named six.moves


Expected results:

[root@radar-shared-development aboutte]# aws --help
usage: aws [options] <command> <subcommand> [<subcommand> ...] [parameters]
To see help text, you can run:

  aws help
  aws <command> help
  aws <command> <subcommand> help
aws: error: too few arguments


Additional info:

It is not just aws --help that is failing.  That is just the easiest command to demonstrate the issue.  If you have AWS credentials setup I would also expect this command to work, as an example:

aws --region us-east-1 cloudtrail describe-trails

All aws commands fail with the reported error above.

Comment 1 andyboutte 2016-09-30 17:21:24 UTC
I just tried the version of awscli in the testing branch and am getting the same results.


[root@radar-kitchen-development tmp]# rpm -qa |grep aws
awscli-1.10.67-1.el7.noarch

[root@radar-kitchen-development tmp]# aws --help
Traceback (most recent call last):
  File "/bin/aws", line 19, in <module>
    import awscli.clidriver
  File "/usr/lib/python2.7/site-packages/awscli/clidriver.py", line 17, in <module>
    import botocore.session
  File "/usr/lib/python2.7/site-packages/botocore/session.py", line 25, in <module>
    import botocore.configloader
  File "/usr/lib/python2.7/site-packages/botocore/configloader.py", line 18, in <module>
    from six.moves import configparser
ImportError: No module named six.moves

Comment 2 Fedora Update System 2016-10-03 06:49:12 UTC
awscli-1.11.0-1.el7, python-botocore-1.4.58-1.el7, python-s3transfer-0.1.5-1.el7 has been pushed to the Fedora EPEL 7 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2016-6893e04314

Comment 3 andyboutte 2016-10-03 19:26:25 UTC
Here is my experience when using the testing repository (I will be the first to admit I have no experience using the testing repository, please let me know if I have enabled it incorrectly):


[root@radar-kitchen-development yum.repos.d]# cat /etc/yum.repos.d/tesing-epel.repo
# This file was generated by Chef
# Do NOT modify this file by hand.

[epel]
name=Extra Packages for $releasever - $basearch - Testing
enabled=1
failovermethod=priority
gpgcheck=1
gpgkey=https://dl.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-7
mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=testing-epel7&arch=$basearch
[root@radar-kitchen-development yum.repos.d]# yum clean all
Loaded plugins: fastestmirror
Cleaning repos: base epel extras updates
Cleaning up everything
[root@radar-kitchen-development yum.repos.d]# yum install awscli
Loaded plugins: fastestmirror
base                                                                                                                                                   | 3.6 kB  00:00:00
epel                                                                                                                                                   | 4.3 kB  00:00:00
extras                                                                                                                                                 | 3.4 kB  00:00:00
updates                                                                                                                                                | 3.4 kB  00:00:00
(1/7): base/7/x86_64/group_gz                                                                                                                          | 155 kB  00:00:00
(2/7): epel/x86_64/updateinfo                                                                                                                          |  80 kB  00:00:00
epel/x86_64/primary_db         FAILED                                          ====                                                         ] 1.5 MB/s | 1.4 MB  00:00:08 ETA
http://mirror.datto.com/fedora/epel/testing/7/x86_64/repodata/ca0ae303ebec09322f425e67fac1978923b8b005440675a353bb2c03bee88b75-primary.sqlite.xz: [Errno 14] HTTP Error 404 - Not Found
Trying other mirror.
To address this issue please refer to the below knowledge base article

https://access.redhat.com/articles/1320623

If above article doesn't help to resolve this issue please create a bug on https://bugs.centos.org/

(3/7): epel/x86_64/group_gz                                                                                                                            | 170 kB  00:00:01
(4/7): base/7/x86_64/primary_db                                                                                                                        | 5.3 MB  00:00:01
(5/7): epel/x86_64/primary_db                                                                                                                          | 572 kB  00:00:00
(6/7): extras/7/x86_64/primary_db                                                                                                                      | 165 kB  00:00:01
(7/7): updates/7/x86_64/primary_db                                                                                                                     | 7.8 MB  00:00:03
Determining fastest mirrors
 * base: centos.unixheads.org
 * epel: mirror.cs.pitt.edu
 * extras: mirror.datto.com
 * updates: mirror.cs.pitt.edu
Resolving Dependencies
--> Running transaction check
---> Package awscli.noarch 0:1.11.0-1.el7 will be installed
--> Processing Dependency: python2-botocore = 1.4.58 for package: awscli-1.11.0-1.el7.noarch
--> Processing Dependency: python2-s3transfer >= 0.1.0 for package: awscli-1.11.0-1.el7.noarch
--> Processing Dependency: python2-rsa >= 3.1.2 for package: awscli-1.11.0-1.el7.noarch
--> Processing Dependency: python-docutils >= 0.10 for package: awscli-1.11.0-1.el7.noarch
--> Processing Dependency: python-colorama >= 0.2.5 for package: awscli-1.11.0-1.el7.noarch
--> Running transaction check
---> Package awscli.noarch 0:1.11.0-1.el7 will be installed
--> Processing Dependency: python2-rsa >= 3.1.2 for package: awscli-1.11.0-1.el7.noarch
--> Processing Dependency: python-colorama >= 0.2.5 for package: awscli-1.11.0-1.el7.noarch
---> Package python-docutils.noarch 0:0.11-0.2.20130715svn7687.el7 will be installed
--> Processing Dependency: python-imaging for package: python-docutils-0.11-0.2.20130715svn7687.el7.noarch
---> Package python2-botocore.noarch 0:1.4.58-1.el7 will be installed
--> Processing Dependency: python-jmespath >= 0.7.1 for package: python2-botocore-1.4.58-1.el7.noarch
--> Processing Dependency: python-dateutil >= 1.4 for package: python2-botocore-1.4.58-1.el7.noarch
--> Processing Dependency: python-six for package: python2-botocore-1.4.58-1.el7.noarch
---> Package python2-s3transfer.noarch 0:0.1.5-1.el7 will be installed
--> Processing Dependency: python-futures for package: python2-s3transfer-0.1.5-1.el7.noarch
--> Running transaction check
---> Package awscli.noarch 0:1.11.0-1.el7 will be installed
--> Processing Dependency: python2-rsa >= 3.1.2 for package: awscli-1.11.0-1.el7.noarch
--> Processing Dependency: python-colorama >= 0.2.5 for package: awscli-1.11.0-1.el7.noarch
---> Package python-dateutil.noarch 0:1.5-7.el7 will be installed
---> Package python-pillow.x86_64 0:2.0.0-19.gitd1c6db8.el7 will be installed
--> Processing Dependency: libwebp.so.4()(64bit) for package: python-pillow-2.0.0-19.gitd1c6db8.el7.x86_64
---> Package python-six.noarch 0:1.9.0-2.el7 will be installed
---> Package python2-botocore.noarch 0:1.4.58-1.el7 will be installed
--> Processing Dependency: python-jmespath >= 0.7.1 for package: python2-botocore-1.4.58-1.el7.noarch
---> Package python2-s3transfer.noarch 0:0.1.5-1.el7 will be installed
--> Processing Dependency: python-futures for package: python2-s3transfer-0.1.5-1.el7.noarch
--> Running transaction check
---> Package awscli.noarch 0:1.11.0-1.el7 will be installed
--> Processing Dependency: python2-rsa >= 3.1.2 for package: awscli-1.11.0-1.el7.noarch
--> Processing Dependency: python-colorama >= 0.2.5 for package: awscli-1.11.0-1.el7.noarch
---> Package libwebp.x86_64 0:0.3.0-3.el7 will be installed
---> Package python2-botocore.noarch 0:1.4.58-1.el7 will be installed
--> Processing Dependency: python-jmespath >= 0.7.1 for package: python2-botocore-1.4.58-1.el7.noarch
---> Package python2-s3transfer.noarch 0:0.1.5-1.el7 will be installed
--> Processing Dependency: python-futures for package: python2-s3transfer-0.1.5-1.el7.noarch
--> Finished Dependency Resolution
Error: Package: python2-botocore-1.4.58-1.el7.noarch (epel)
           Requires: python-jmespath >= 0.7.1
Error: Package: awscli-1.11.0-1.el7.noarch (epel)
           Requires: python2-rsa >= 3.1.2
Error: Package: awscli-1.11.0-1.el7.noarch (epel)
           Requires: python-colorama >= 0.2.5
Error: Package: python2-s3transfer-0.1.5-1.el7.noarch (epel)
           Requires: python-futures
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest

Comment 4 Fabio Alessandro Locati 2016-10-04 14:08:50 UTC
I think you did something weird with the repos.

This is what I did on a freshly installed machine:

* sudo yum install -y epel-release
* sudo yum install -y awscli --enablerepo=epel-testing
* aws help

Everything works as expected

Comment 5 andyboutte 2016-10-04 14:38:34 UTC
Thanks Fabio.  I can confirm the packages in the testing repo are working as expected.

Comment 6 Fedora Update System 2016-10-21 15:52:17 UTC
awscli-1.11.0-1.el7, python-botocore-1.4.58-1.el7, python-s3transfer-0.1.5-1.el7 has been pushed to the Fedora EPEL 7 stable repository. If problems still persist, please make note of it in this bug report.