Skip to content

Commit

Permalink
Merge branch 'release-1.2.9' into develop
Browse files Browse the repository at this point in the history
* release-1.2.9:
  Bumping version to 1.2.9
  Update changelog with latest features
  Add banner for new region
  Remove str() call from part_number args
  Update CloudTrail customization call format.
  Update completer tests with new region
  • Loading branch information
jamesls committed Dec 20, 2013
2 parents 8eddfce + a24750c commit 3e5fd9f
Show file tree
Hide file tree
Showing 9 changed files with 53 additions and 15 deletions.
15 changes: 13 additions & 2 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,25 @@
CHANGELOG
=========

Next Release (TBD)
==================
1.2.9
=====

* Fix issue 548 where ``--include/--exclude`` arguments for various
``aws s3`` commands were prepending the CWD instead of the source
directory for filter patterns
* Fix issue 552 where a remote location without a trailing slash would
show a malformed XML error when using various ``aws s3`` commands
* Add support for tagging in ``aws emr`` command
* Add support for georestrictions in ``aws cloudfront`` command
* Add support for new audio compression codecs in the
``aws elastictranscoder`` command
* Update the ``aws cloudtrail`` command to the latest API
* Add support for the new China (Beijing) Region. Note: Although the AWS CLI
now includes support for the newly announced China (Beijing)
Region, the service endpoints will not be accessible until the Region’s
limited preview is launched in early 2014. To find out more about the new
Region and request a limited preview account, please visit
http://www.amazonaws.cn/.


1.2.8
Expand Down
2 changes: 1 addition & 1 deletion awscli/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
"""
import os

__version__ = '1.2.8'
__version__ = '1.2.9'

#
# Get our data path to be added to botocore's search path
Expand Down
14 changes: 7 additions & 7 deletions awscli/customizations/cloudtrail.py
Original file line number Diff line number Diff line change
Expand Up @@ -293,25 +293,25 @@ def upsert_cloudtrail_config(self, name, bucket, prefix, topic, gse):
"""
sys.stdout.write('Creating/updating CloudTrail configuration...\n')
config = {
'Name': name
'name': name
}

if bucket is not None:
config['S3BucketName'] = bucket
config['s3_bucket_name'] = bucket

if prefix is not None:
config['S3KeyPrefix'] = prefix
config['s3_key_prefix'] = prefix

if topic is not None:
config['SnsTopicName'] = topic
config['sns_topic_name'] = topic

if gse is not None:
config['IncludeGlobalServiceEvents'] = gse
config['include_global_service_events'] = gse

if not self.UPDATE:
self.cloudtrail.CreateTrail(trail=config)
self.cloudtrail.CreateTrail(**config)
else:
self.cloudtrail.UpdateTrail(trail=config)
self.cloudtrail.UpdateTrail(**config)

return self.cloudtrail.DescribeTrails()

Expand Down
4 changes: 2 additions & 2 deletions awscli/customizations/s3/tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ def __call__(self):
src_bucket, src_key = find_bucket_key(self._filename.src)
params = {'endpoint': self._filename.endpoint,
'bucket': bucket, 'key': key,
'part_number': str(self._part_number),
'part_number': self._part_number,
'upload_id': upload_id,
'copy_source': '%s/%s' % (src_bucket, src_key),
'copy_source_range': range_param}
Expand Down Expand Up @@ -209,7 +209,7 @@ def __call__(self):
body = self._read_part()
params = {'endpoint': self._filename.endpoint,
'bucket': bucket, 'key': key,
'part_number': str(self._part_number),
'part_number': self._part_number,
'upload_id': upload_id,
'body': body}
try:
Expand Down
2 changes: 1 addition & 1 deletion doc/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
# The short X.Y version.
version = '1.2'
# The full version, including alpha/beta/rc tags.
release = '1.2.8'
release = '1.2.9'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down
10 changes: 10 additions & 0 deletions doc/source/guzzle_sphinx_theme/guzzle_sphinx_theme/layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,16 @@
</div>
</div>
</div>
<div id="capabilities-banner" class="note">
AWS services or capabilities described in AWS Documentation may vary
by region/location. Click <a href="http://docs.amazonaws.cn/en_us/aws/latest/userguide/api.html">Getting Started with Amazon AWS</a>
to see specific differences applicable to the China (Beijing) Region.
</div>
<script type="text/javascript">
if (!window.location.hostname.match(/\.cn/)) {
document.getElementById('capabilities-banner').style.display = 'none';
}
</script>
{{ super() }}
{% endblock %}

Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import awscli


requires = ['botocore>=0.28.0,<0.29.0',
requires = ['botocore>=0.29.0,<0.30.0',
'bcdoc>=0.12.0,<0.13.0',
'six>=1.1.0',
'colorama==0.2.5',
Expand Down
16 changes: 16 additions & 0 deletions tests/unit/customizations/test_cloudtrail.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,22 @@ def test_sns_create_already_exists(self):
with self.assertRaises(Exception):
self.subscribe.setup_new_topic('test2')

def test_cloudtrail_new_call_format(self):
self.subscribe.cloudtrail = Mock()
self.subscribe.cloudtrail.CreateTrail = Mock(return_value={})
self.subscribe.cloudtrail.DescribeTrail = Mock(return_value={})

self.subscribe.upsert_cloudtrail_config('test', 'bucket', 'prefix',
'topic', True)

self.subscribe.cloudtrail.CreateTrail.assert_called_with(
name='test',
s3_bucket_name='bucket',
s3_key_prefix='prefix',
sns_topic_name='topic',
include_global_service_events=True
)


class TestCloudTrailSessions(BaseAWSCommandParamsTest):
def test_sessions(self):
Expand Down
3 changes: 2 additions & 1 deletion tests/unit/test_completer.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,8 @@
'sa-east-1', 'ap-southeast-1',
'ap-southeast-2', 'us-west-2',
'us-west-1', 'eu-west-1',
'us-gov-west-1', 'fips-us-gov-west-1'])),
'us-gov-west-1', 'fips-us-gov-west-1',
'cn-north-1'])),
('aws ec2 --debug describe-instances --instance-ids ', -1,
set([])),
('aws ec2 --debug describe-instances --instance-ids i-12345678 - ', -1,
Expand Down

0 comments on commit 3e5fd9f

Please sign in to comment.