awscli now depends on python3-botocore >= 1.4

Bug #1654315 reported by Scott G. Miller
20
This bug affects 2 people
Affects Status Importance Assigned to Milestone
awscli (Debian)
Fix Released
Unknown
awscli (Ubuntu)
Fix Released
Critical
Kamal Mostafa
Xenial
Fix Released
Critical
Kamal Mostafa
Yakkety
Fix Released
Critical
Kamal Mostafa
Zesty
Fix Released
Critical
Kamal Mostafa

Bug Description

1) Description: Ubuntu 16.04.1 LTS
Release: 16.04

2) 1.11.13-1~16.04.0
3) Run aws (even just for cli help), no crash
4) Crashes

More info:

After the latest update of awscli to 1.11.13-1~16.04.0 on Xenial, aws crashes immediately with the following Python trace:

$ aws
Traceback (most recent call last):
  File "/usr/bin/aws", line 27, in <module>
    sys.exit(main())
  File "/usr/bin/aws", line 23, in main
    return awscli.clidriver.main()
  File "/usr/lib/python3/dist-packages/awscli/clidriver.py", line 50, in main
    return driver.main()
  File "/usr/lib/python3/dist-packages/awscli/clidriver.py", line 176, in main
    parser = self._create_parser()
  File "/usr/lib/python3/dist-packages/awscli/clidriver.py", line 157, in _create_parser
    command_table = self._get_command_table()
  File "/usr/lib/python3/dist-packages/awscli/clidriver.py", line 91, in _get_command_table
    self._command_table = self._build_command_table()
  File "/usr/lib/python3/dist-packages/awscli/clidriver.py", line 111, in _build_command_table
    command_object=self)
  File "/usr/lib/python3/dist-packages/botocore/session.py", line 675, in emit
    return self._events.emit(event_name, **kwargs)
  File "/usr/lib/python3/dist-packages/botocore/hooks.py", line 226, in emit
    return self._emit(event_name, kwargs)
  File "/usr/lib/python3/dist-packages/botocore/hooks.py", line 209, in _emit
    response = handler(**kwargs)
  File "/usr/lib/python3/dist-packages/awscli/customizations/preview.py", line 70, in mark_as_preview
    service_name=original_command.service_model.service_name,
  File "/usr/lib/python3/dist-packages/awscli/clidriver.py", line 351, in service_model
    return self._get_service_model()
  File "/usr/lib/python3/dist-packages/awscli/clidriver.py", line 368, in _get_service_model
    api_version = self.session.get_config_variable('api_versions').get(
AttributeError: 'NoneType' object has no attribute 'get'

Upgrading to python3-botocore from xenial-updates (currently 1.4.70-1~16.04.0) solves the problem. This took out a number of our production instances which used the cli for SSH authentication.

-----------------------------------------

SRU Xenial/Yakkety justification

[Impact]

 * awscli (1.11.13-1) and its dependencies including python3-botocore were
   recently no-change-backported to Yakkety and Xenial. However, its specified
   python3-botocore versioned dependency is insufficient (needs a newer version
   of python3-botocore than specified).

 * If awscli is updated on Y or X (to version 1.11.13-1~whatever) without also
   updating python3-botocore, the 'aws' command fails completely.

 * The insufficient versioned dep is a bug in Debian and Zesty too (but don't
   manifest since those only supply the newer python3-botocore version).

 * To fix this, we've bumped up the versioned dep in Zesty's awscli
   (1.11.13-1ubuntu1), and now that needs no-change-backport back to Y and X.

 * The issue has also been bug reported in Debian.

[Test Case]

 * On Y or X, manually update awscli to version (1.11.13-1~something), but
   do not update python3-botocore (leave it at version 1.3.23-1).

   Run 'aws' and observe crash instead of expected command line usage/help
   message.

[Regression Potential]

 * None. This update _only_ increases the versioned dependency, so as to
   force python3-botocore to update along with awscli.

Changed in awscli (Ubuntu):
status: New → Triaged
importance: Undecided → Critical
Revision history for this message
Christian Ehrhardt  (paelzer) wrote :

Can't be seen on a system that ran global updates, but makes sens if only awscli is updated/installed and still on the release.

I flagged critical for the risk of loosing logins.

Release came out with
https://launchpad.net/ubuntu/yakkety/amd64/python3-botocore/1.3.23-1

I was not part of that work, but as far as I understand it that seems to be a regression of the SRU that was made.
https://launchpad.net/ubuntu/+source/awscli/+publishinghistory
https://launchpad.net/ubuntu/+source/python-botocore/+publishinghistory

tags: added: regression-update
Revision history for this message
Scott G. Miller (sgmiller) wrote :

That's correct. We run our deployments using Ansible, which runs individual package installs & updates. Since it was installing 'latest' on awscli but obviously not its dependencies, we hit the bug.

tags: added: xenial
Changed in awscli (Ubuntu Zesty):
assignee: nobody → Kamal Mostafa (kamalmostafa)
Changed in awscli (Ubuntu Yakkety):
assignee: nobody → Kamal Mostafa (kamalmostafa)
Changed in awscli (Ubuntu Xenial):
assignee: nobody → Kamal Mostafa (kamalmostafa)
Changed in awscli (Ubuntu Zesty):
status: Triaged → In Progress
Changed in awscli (Ubuntu Yakkety):
status: New → In Progress
Changed in awscli (Ubuntu Xenial):
status: New → In Progress
Revision history for this message
Kamal Mostafa (kamalmostafa) wrote :

Fixed awscli package for Zesty, Yakkety, and Xenial (which bumps up the python3-botocore dependency) is available here:
https://launchpad.net/~kamalmostafa/+archive/ubuntu/awscli

Revision history for this message
Scott G. Miller (sgmiller) wrote :

Thanks!

Changed in awscli (Debian):
status: Unknown → New
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package awscli - 1.11.13-1ubuntu1

---------------
awscli (1.11.13-1ubuntu1) zesty; urgency=high

  * debian/control: awscli 1.11.? requires python3-botocore(>=1.4.?)
     - Depend on python3-botocore(>=1.4.70) (LP: #1654315)

 -- Kamal Mostafa <email address hidden> Tue, 10 Jan 2017 11:25:28 -0800

Changed in awscli (Ubuntu Zesty):
status: In Progress → Fix Released
Revision history for this message
Andy Whitcroft (apw) wrote : Please test proposed package

Hello Scott, or anyone else affected,

Accepted awscli into yakkety-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/awscli/1.11.13-1ubuntu1~16.10.0 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

Changed in awscli (Ubuntu Yakkety):
status: In Progress → Fix Committed
tags: added: verification-needed
Changed in awscli (Ubuntu Yakkety):
importance: Undecided → Critical
Changed in awscli (Ubuntu Xenial):
importance: Undecided → Critical
status: In Progress → Fix Committed
Revision history for this message
Andy Whitcroft (apw) wrote :

Hello Scott, or anyone else affected,

Accepted awscli into xenial-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/awscli/1.11.13-1ubuntu1~16.04.0 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

description: updated
Revision history for this message
Kamal Mostafa (kamalmostafa) wrote :

I've verified that the -proposed awscli packages for Y and X both work as intended (apt requires python3-botocore to update to the requisite version), thus fixing the 'aws' command failure.

tags: added: verification-done yakkety
removed: verification-needed
Revision history for this message
Scott G. Miller (sgmiller) wrote :

I can confirm, after downgrading my python3-botocore back to 1.3, adding proposed, removing them reinstalling awscli, it correctly requires the latest botocore and aws works as expected.

Bug fixed.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package awscli - 1.11.13-1ubuntu1~16.04.0

---------------
awscli (1.11.13-1ubuntu1~16.04.0) xenial; urgency=high

  * No-change backport to Xenial for LP: #1654315

awscli (1.11.13-1ubuntu1) zesty; urgency=high

  * debian/control: awscli 1.11.? requires python3-botocore(>=1.4.?)
     - Depend on python3-botocore(>=1.4.70) (LP: #1654315)

awscli (1.11.13-1) unstable; urgency=medium

  * New upstream version 1.11.13 (Closes: #819451)
  * debian/patches: Refresh patches.

 -- Kamal Mostafa <email address hidden> Tue, 10 Jan 2017 11:53:22 -0800

Changed in awscli (Ubuntu Xenial):
status: Fix Committed → Fix Released
Revision history for this message
Adam Conrad (adconrad) wrote : Update Released

The verification of the Stable Release Update for awscli has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package awscli - 1.11.13-1ubuntu1~16.10.0

---------------
awscli (1.11.13-1ubuntu1~16.10.0) yakkety; urgency=high

  * No-change backport to Yakkety for LP: #1654315

awscli (1.11.13-1ubuntu1) zesty; urgency=high

  * debian/control: awscli 1.11.? requires python3-botocore(>=1.4.?)
     - Depend on python3-botocore(>=1.4.70) (LP: #1654315)

awscli (1.11.13-1) unstable; urgency=medium

  * New upstream version 1.11.13 (Closes: #819451)
  * debian/patches: Refresh patches.

 -- Kamal Mostafa <email address hidden> Tue, 10 Jan 2017 11:53:22 -0800

Changed in awscli (Ubuntu Yakkety):
status: Fix Committed → Fix Released
Changed in awscli (Debian):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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