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

Useless message: "FATAL: Found legacy version file 'main.tf' with unsupported required version constraint expression" #63

Open
mjreed-wbd opened this issue Oct 17, 2022 · 3 comments

Comments

@mjreed-wbd
Copy link

I appreciate that the plugin tries to determine the version to run based on the terraform code, but if it's not going to parse constraints that are valid to TF, that's no help.

It only displays the message when I don't have a "local" or "shell" version configured via asdf itself, but I do have one selected globally. And it's clearly not a "FATAL" condition, since it proceeds to run that version after printing the message out.

Would rather just get rid of the message.

@swallowtail62
Copy link

You can suppress it by changing the configuration file as follows.

~/.asdfrc

legacy_version_file = no

@aclarknexient
Copy link

aclarknexient commented Apr 15, 2023

Unfortunately I have that setting enabled to work with https://github.com/asdf-vm/asdf-nodejs

Would it be possible to create a way to disable that message? If I deployed this across my teams, it would cause some support calls from confused developers.

@adamroyjones
Copy link

An alternative is to use rtx with a configuration file that looks like this

# ~/.config/rtx/config.toml
[settings]
legacy_version_file_disable_tools = ["terraform"]

to selectively disable this for Terraform.

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

No branches or pull requests

4 participants