aws-cloudformation / aws-cloudformation/cloudformation-coverage-roadmap
Getting ModuleNotFoundError: No module named 'imp' while running cfn-signal with python3.12
- Dominant language
- No language data
- Stars
- 1.1k
- Forks
- 62
- PR merge metrics
- No merged PRs in 30d
Description
### Name of the resource
Other
### Resource Name
cfn-signal
### Issue Description
`cfn-signal` does not work with python3.12
### Expected Behavior
`cfn-signal` should be able to send the signal succesfully
### Observed Behavior
Traceback (most recent call last):
File "/usr/local/bin/cfn-signal", line 20, in
from cfnbootstrap.cfn_client import CloudFormationClient
File "/usr/local/lib/python3.12/site-packages/cfnbootstrap/cfn_client.py", line 24, in
from cfnbootstrap import aws_client, util
File "/usr/local/lib/python3.12/site-packages/cfnbootstrap/aws_client.py", line 23, in
from cfnbootstrap import util, public_constants
File "/usr/local/lib/python3.12/site-packages/cfnbootstrap/util.py", line 17, in
from cfnbootstrap import endpoint_tool
File "/usr/local/lib/python3.12/site-packages/cfnbootstrap/endpoint_tool.py", line 16, in
from cfnbootstrap.resources import documents
File "/usr/local/lib/python3.12/site-packages/cfnbootstrap/resources/documents/__init__.py", line 17, in
import imp
ModuleNotFoundError: No module named 'imp'
### Test Cases
Install python3.12 on Amazon Linux 2023 or Amazon Linux 2.
Use python3.12 to run the `cfn-signal`
### Other Details
_No response_
Contributor guide
Research direction
Start by reproducing cfn-signal with Python 3.12 on Amazon Linux 2023 or Amazon Linux 2 and follow the traceback through cfnbootstrap/resources/documents/__init__.py. Confirm that the resulting cfn-signal invocation can send its signal successfully without the ModuleNotFoundError for imp.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, python
- Domain
- cloud
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100