aws / aws-ec2-instance-connect-cli

This is an all-in-one client for EC2 Instance Connect that handles key brokerage and establishing connection to EC2 Instances through an interface near-identical to standard system ssh, sftp, and other utilities.
Apache License 2.0
159 stars 42 forks source link

ImportError: cannot import name _thread on MacOS #12

Open villelahdenvuo opened 4 years ago

villelahdenvuo commented 4 years ago
Stack Trace Traceback (most recent call last): File "/Users/ville.lahdenvuo/Library/Python/2.7/bin/mssh", line 17, in from ec2instanceconnectcli import mops File "/Users/ville.lahdenvuo/Library/Python/2.7/lib/python/site-packages/ec2instanceconnectcli/mops.py", line 17, in from ec2instanceconnectcli.EC2InstanceConnectCLI import EC2InstanceConnectCLI File "/Users/ville.lahdenvuo/Library/Python/2.7/lib/python/site-packages/ec2instanceconnectcli/EC2InstanceConnectCLI.py", line 19, in import botocore.session File "/Users/ville.lahdenvuo/Library/Python/2.7/lib/python/site-packages/botocore/session.py", line 30, in import botocore.credentials File "/Users/ville.lahdenvuo/Library/Python/2.7/lib/python/site-packages/botocore/credentials.py", line 26, in from dateutil.parser import parse File "/Users/ville.lahdenvuo/Library/Python/2.7/lib/python/site-packages/dateutil/parser/__init__.py", line 2, in from ._parser import parse, parser, parserinfo File "/Users/ville.lahdenvuo/Library/Python/2.7/lib/python/site-packages/dateutil/parser/_parser.py", line 50, in from .. import tz File "/Users/ville.lahdenvuo/Library/Python/2.7/lib/python/site-packages/dateutil/tz/__init__.py", line 2, in from .tz import * File "/Users/ville.lahdenvuo/Library/Python/2.7/lib/python/site-packages/dateutil/tz/tz.py", line 21, in from six.moves import _thread ImportError: cannot import name _thread

Same issue as: https://github.com/awslabs/aws-shell/issues/161 and same solution works.

CptTZ commented 4 years ago

Thanks for reporting this issue!

aws-shell and our service are both using botocore for accessing AWS services under the hood. Whenever botocore failed, mssh would fail as well.

There are documents for addressing this issue: https://github.com/awslabs/aws-shell#installation, I think we can note that in our doc as well.