aws / aws/aws-ec2-instance-connect-cli

ImportError: cannot import name _thread on MacOS

Open
#12 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
168
Forks
43
PR merge metrics
No merged PRs in 30d

Description

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.

Contributor guide

Open the contributing guide

Research direction

Start with the reported mssh import path through ec2instanceconnectcli/mops.py and the failing import in dateutil/tz/tz.py. Compare the linked aws-shell issue and its referenced solution, then verify that the CLI imports successfully on macOS without the reported ImportError.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.