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

Support for terraform 0.15 #103

Open
wrazik opened this issue Apr 20, 2021 · 5 comments
Open

Support for terraform 0.15 #103

wrazik opened this issue Apr 20, 2021 · 5 comments

Comments

@wrazik
Copy link

wrazik commented Apr 20, 2021

Terraform version 0.15.0 did remove flat --var-file, which is used for creating temporary file:

  cmds += [f"-var-file={filename}"]

Terraform release note https://github.com/hashicorp/terraform/blob/v0.15/CHANGELOG.md:

The -var and -var-file options are no longer available on terraform validate. These were deprecated and have had no effect since Terraform v0.12

User see output:

error: b'Too many command line arguments. Did you mean to use -chdir?\n'
@rallyben
Copy link

rallyben commented Jun 7, 2021

Given the slew of differences between Terraform below 0.12.x and above 0.12.x, does it make sense to drop support of 0.11 and below in the next major release?

@rallyben
Copy link

rallyben commented Jun 7, 2021

@Spikeophant
I found this post:

A coworker and I are going to rewrite this entire project, focusing on tf 12 and fully supporting all functionality therein, as well as decoupling somethings that we feel should not be coupled as tightly as they are in the options building that we have today. If anyone is interested in working with us on this we feel it will take 2 weekends of work, and one of those will be planning so we can address all bugs in the backlog. My work is sponsoring us to do this, so he and I will be able to host code reviews online, planning online, etc.
I have been very busy at work and we use this project heavily, we'd like to finally get the improvements I have been wanting to do out the door. The new python terraform version will rev to 0.12.0, and we'll leave the 0.10 codebase out there for bugfixes if anyone wants to do so. We will ONLY support TF 12+ in the rewrite however, and ONLY python 3.6+.
Let me know if you are interested and I'll get you info on dates.
Thanks! Spikeophant

I'm quite invested in python-terraform and am I interested on the status. Is this going to be a new package? Is the current work published to GitHub?

@james-nesbitt
Copy link

0.15.2 and 1.0.0 are probably more important targets at this time.

@rafaelfelix
Copy link

rafaelfelix commented Nov 11, 2021

for those running into this issue, I managed to get around it by calling Terraform().cmd() directly, like this:

from python_terraform import Terraform
tf = Terraform()
tf.cmd("init -reconfigure -backend=true")

ugly, I know. but does the job while this issue is not properly fixed.

@naorlivne
Copy link

For me personally the issue is with 0.15+ but as I prefer sticking to the latest version if #116 will be merged and allow us to work with the latest terraform 1.x.x I'll be happy closing this ticket

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants