Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Installation of terraform-compliance using pip install on windows misses dependency check on windows-curses module #323

Closed
vmathur2004 opened this issue Jul 13, 2020 · 5 comments
Assignees
Labels
bug waiting for confirmation Workaround/Fix applied, waiting for confirmation

Comments

@vmathur2004
Copy link

Description :
When terraform-compliance is installed using pip install method the installation is reported as successful however an error is thrown upon execution of terraform-compliance complaining of inability to import module terrain because of a dependent module '_curses' being missing

Operating system: Windows 10 Enterprise 64-bit

To Reproduce

  1. Ensure that a Windows 10 enterprise 64-bit OS is selected where terraform-compliance has not be installed / used before

  2. Open a command prompt with elevated privilages and execute pip install terraform-compliance

  3. Check that the pip install is successful

  4. Execute terraform-compliance assuming terraform plan output, feature to tests and steps are defined.

  5. The execution fails with the below error:
    ERROR: Unable to import module 'terrain' from 'c:\users\username\appdata\local\programs\python\python37-32\lib\site-packages\terraform_compliance\steps\terrain.py': No module named '_curses'

Expected behavior :
The pip installation should check for all dependent modules to be present OR the installation instructions should clearly mention an explicit download of dependencies

Tested versions :

  • terraform-compliance version (v1.2.8)
  • terraform version (v0.12.24)
  • python runtime version, if running as a python package (3.7.3)

Additional context
The problem can be resolved by manually installing the curses module for windows using the following command:

pip install windows-curses

@eerkunt
Copy link
Member

eerkunt commented Jul 13, 2020

Hello @vmathur2004, thanks for the issue 🎉

Yes, this was a mistake within 1.2.8, the issue is fixed within 1.2.9, releasing in few minutes.

@eerkunt
Copy link
Member

eerkunt commented Jul 13, 2020

Just released 1.2.9, must be in PyPi within few minutes. Can you have a try and let us know please ?

Thanks 🎉

@eerkunt eerkunt added the waiting for confirmation Workaround/Fix applied, waiting for confirmation label Jul 13, 2020
@vmathur2004
Copy link
Author

Sure, will do when i get a chance during the day today

@vmathur2004
Copy link
Author

Confirm this to be fixed in v 1.2.9 - the dependency on windows-curses seems to have been removed.

@ghost
Copy link

ghost commented Jul 13, 2020

This issue's conversation is now locked. If you want to continue this discussion please open a new issue.

@ghost ghost locked and limited conversation to collaborators Jul 13, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug waiting for confirmation Workaround/Fix applied, waiting for confirmation
Projects
None yet
Development

No branches or pull requests

2 participants