Skip to content

Commit

Permalink
Merge branch 'release-1.27.6'
Browse files Browse the repository at this point in the history
* release-1.27.6:
  Bumping version to 1.27.6
  Update changelog based on model updates
  Add mandoc fallback test
  help: if groff is not found, try mandoc
  • Loading branch information
aws-sdk-python-automation committed Nov 9, 2022
2 parents 48dcd12 + 65403a0 commit f3f5f70
Show file tree
Hide file tree
Showing 8 changed files with 75 additions and 11 deletions.
37 changes: 37 additions & 0 deletions .changes/1.27.6.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
[
{
"category": "docs",
"description": "Fixes `#6918 <https://github.com/aws/aws-cli/issues/6918>`__ and `#7400 <https://github.com/aws/aws-cli/issues/7400>`__. The CLI falls back on mandoc if groff isn't available.",
"type": "enhancement"
},
{
"category": "``connect``",
"description": "This release adds new fields SignInUrl, UserArn, and UserId to GetFederationToken response payload.",
"type": "api-change"
},
{
"category": "``connectcases``",
"description": "This release adds the ability to disable templates through the UpdateTemplate API. Disabling templates prevents customers from creating cases using the template. For more information see https://docs.aws.amazon.com/cases/latest/APIReference/Welcome.html",
"type": "api-change"
},
{
"category": "``ec2``",
"description": "Amazon EC2 Trn1 instances, powered by AWS Trainium chips, are purpose built for high-performance deep learning training. u-24tb1.112xlarge and u-18tb1.112xlarge High Memory instances are purpose-built to run large in-memory databases.",
"type": "api-change"
},
{
"category": "``groundstation``",
"description": "This release adds the preview of customer-provided ephemeris support for AWS Ground Station, allowing space vehicle owners to provide their own position and trajectory information for a satellite.",
"type": "api-change"
},
{
"category": "``mediapackage-vod``",
"description": "This release adds \"IncludeIframeOnlyStream\" for Dash endpoints.",
"type": "api-change"
},
{
"category": "``endpoint-rules``",
"description": "Update endpoint-rules command to latest version",
"type": "api-change"
}
]
12 changes: 12 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,18 @@
CHANGELOG
=========

1.27.6
======

* enhancement:docs: Fixes `#6918 <https://github.com/aws/aws-cli/issues/6918>`__ and `#7400 <https://github.com/aws/aws-cli/issues/7400>`__. The CLI falls back on mandoc if groff isn't available.
* api-change:``connect``: This release adds new fields SignInUrl, UserArn, and UserId to GetFederationToken response payload.
* api-change:``connectcases``: This release adds the ability to disable templates through the UpdateTemplate API. Disabling templates prevents customers from creating cases using the template. For more information see https://docs.aws.amazon.com/cases/latest/APIReference/Welcome.html
* api-change:``ec2``: Amazon EC2 Trn1 instances, powered by AWS Trainium chips, are purpose built for high-performance deep learning training. u-24tb1.112xlarge and u-18tb1.112xlarge High Memory instances are purpose-built to run large in-memory databases.
* api-change:``groundstation``: This release adds the preview of customer-provided ephemeris support for AWS Ground Station, allowing space vehicle owners to provide their own position and trajectory information for a satellite.
* api-change:``mediapackage-vod``: This release adds "IncludeIframeOnlyStream" for Dash endpoints.
* api-change:``endpoint-rules``: Update endpoint-rules command to latest version


1.27.5
======

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.27.5'
__version__ = '1.27.6'

#
# Get our data path to be added to botocore's search path
Expand Down
13 changes: 8 additions & 5 deletions awscli/help.py
Original file line number Diff line number Diff line change
Expand Up @@ -106,13 +106,16 @@ class PosixHelpRenderer(PagingHelpRenderer):

def _convert_doc_content(self, contents):
man_contents = publish_string(contents, writer=manpage.Writer())
if not self._exists_on_path('groff'):
raise ExecutableNotFoundError('groff')
cmdline = ['groff', '-m', 'man', '-T', 'ascii']
if self._exists_on_path('groff'):
cmdline = ['groff', '-m', 'man', '-T', 'ascii']
elif self._exists_on_path('mandoc'):
cmdline = ['mandoc', '-T', 'ascii']
else:
raise ExecutableNotFoundError('groff or mandoc')
LOG.debug("Running command: %s", cmdline)
p3 = self._popen(cmdline, stdin=PIPE, stdout=PIPE, stderr=PIPE)
groff_output = p3.communicate(input=man_contents)[0]
return groff_output
output = p3.communicate(input=man_contents)[0]
return output

def _send_output_to_pager(self, output):
cmdline = self.get_pager_cmdline()
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.27'
# The full version, including alpha/beta/rc tags.
release = '1.27.5'
release = '1.27.6'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ universal = 0

[metadata]
requires_dist =
botocore==1.29.5
botocore==1.29.6
docutils>=0.10,<0.17
s3transfer>=0.6.0,<0.7.0
PyYAML>=3.10,<5.5
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def find_version(*file_paths):


install_requires = [
'botocore==1.29.5',
'botocore==1.29.6',
'docutils>=0.10,<0.17',
's3transfer>=0.6.0,<0.7.0',
'PyYAML>=3.10,<5.5',
Expand Down
16 changes: 14 additions & 2 deletions tests/unit/test_help.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,13 +96,25 @@ def test_pager_with_args(self):
pager_cmd.split())

@skip_if_windows('Requires posix system.')
def test_no_groff_exists(self):
def test_no_groff_or_mandoc_exists(self):
renderer = FakePosixHelpRenderer()
renderer.exists_on_path['groff'] = False
expected_error = 'Could not find executable named "groff"'
renderer.exists_on_path['mandoc'] = False
expected_error = 'Could not find executable named "groff or mandoc"'
with self.assertRaisesRegex(ExecutableNotFoundError, expected_error):
renderer.render('foo')

@skip_if_windows('Requires POSIX system.')
def test_renderer_falls_back_to_mandoc(self):
stdout = six.StringIO()
renderer = FakePosixHelpRenderer(output_stream=stdout)

renderer.exists_on_path['groff'] = False
renderer.exists_on_path['mandoc'] = True
renderer.mock_popen.communicate.return_value = (b'foo', '')
renderer.render('foo')
self.assertEqual(stdout.getvalue(), 'foo\n')

@skip_if_windows('Requires POSIX system.')
def test_no_pager_exists(self):
fake_pager = 'foobar'
Expand Down

0 comments on commit f3f5f70

Please sign in to comment.