Aws-cli: UnicodeDecodeError: 'ascii' codec can't decode byte... --registry-ids using in aws ecr

Created on 3 Feb 2018  Â·  2Comments  Â·  Source: aws/aws-cli

I am trying to pull ecr-image from my other AWS account:

/home/ec2-user # aws ecr get-login –-registry-ids 111111111 --region us-east-1

Traceback (most recent call last):
File "/bin/aws", line 27, in
sys.exit(main())
File "/bin/aws", line 23, in main
return awscli.clidriver.main()
File "/usr/local/aws/lib/python2.7/site-packages/awscli/clidriver.py", line 59, in main
rc = driver.main()
File "/usr/local/aws/lib/python2.7/site-packages/awscli/clidriver.py", line 233, in main
write_exception(e, outfile=get_stderr_text_writer())
File "/usr/local/aws/lib/python2.7/site-packages/awscli/utils.py", line 194, in write_exception
outfile.write(six.text_type(ex))
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 17: ordinal not in range(128)

/home/ec2-user # aws --version

aws-cli/1.14.32 Python/2.7.5 Linux/4.9.76-38.79.amzn2.x86_64 botocore/1.8.36

It's on AmazonLinux2, Debian8/9 and some other.

closing-soon

Most helpful comment

I am sorry, i found my error - first dash in option "--registry" was Unicode dash character (apparently, I copied this code example from some site).

All 2 comments

Hi @applerom would it be possible to get the debug logs from running this command? I think the unicode error you are getting is being propagated from some other error the CLI is trying to write out but unable to decode properly.

I am sorry, i found my error - first dash in option "--registry" was Unicode dash character (apparently, I copied this code example from some site).

Was this page helpful?
0 / 5 - 0 ratings

Related issues

alexejk picture alexejk  Â·  3Comments

maanbsat picture maanbsat  Â·  3Comments

kangman picture kangman  Â·  3Comments

braddr picture braddr  Â·  3Comments

ronaldpetty picture ronaldpetty  Â·  3Comments