You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The -no-color argument introduced in #208 does not allow terraform-ls to retrieve schemas using terraform providers schema -json since it injects the -no-color argument, making the executed command terraform providers -no-color schema -json which throws an error.
2020/07/10 15:32:52 exec.go:178: Starting /Users/redacted/.local/bin/terraform ["terraform" "providers" "-no-color" "schema" "-json"] in "/Users/redacted/testing"...
2020/07/10 15:32:52 exec.go:144: Waiting for command to finish ...
2020/07/10 15:32:53 root_module.go:453: failed to update plugin cache for /Users/redacted/testing: Unable to retrieve schemas for "/Users/redacted/testing": failed to get schemas: terraform (pid 10436) exited (code 1): exit status 1
stdout: ""
stderr: "Too many command line arguments. Configuration path expected.\n"
Expected Behavior
The terraform providers schema -json command should successfully execute and allow terraform-ls to load the schemas.
Actual Behavior
The terraform providers schema -json command throws the error Too many command line arguments. Configuration path expected.\n since the -no-color argument is injected in the wrong place. This leaves the terraform-ls binary unable to load schemas.
Switching back to terraform-ls version 0.4.1 works.
Perhaps switching the command to terraform providers schema -json -no-color would work since that's a valid command or removing -no-color from this command.
Steps to Reproduce
Configure your Vim/Neovim setup with coc.nvim per the above configuration.
Create a main.tf with the above content.
Execute terraform init as required by terraform-ls.
Edit themain.tf file to let terraform-ls initialize.
Notice that completion is not working.
View the logs for terraform-ls either running terraform-ls with -log-file or using the :CocInfo Vim/Neovim command.
The text was updated successfully, but these errors were encountered:
sudomateo
changed the title
-no-color breaks terraform providers schema command-no-color breaks terraform providers schema -json command
Jul 10, 2020
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the context necessary to investigate further.
ghost
locked and limited conversation to collaborators
Aug 9, 2020
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
The
-no-color
argument introduced in #208 does not allowterraform-ls
to retrieve schemas usingterraform providers schema -json
since it injects the-no-color
argument, making the executed commandterraform providers -no-color schema -json
which throws an error.Server Version
Terraform Version
Client Version
NVIM v0.4.3 with
coc.nvim
.Terraform Configuration Files
Log Output
Expected Behavior
The
terraform providers schema -json
command should successfully execute and allowterraform-ls
to load the schemas.Actual Behavior
The
terraform providers schema -json
command throws the errorToo many command line arguments. Configuration path expected.\n
since the-no-color
argument is injected in the wrong place. This leaves theterraform-ls
binary unable to load schemas.Switching back to
terraform-ls
version0.4.1
works.Perhaps switching the command to
terraform providers schema -json -no-color
would work since that's a valid command or removing-no-color
from this command.Steps to Reproduce
coc.nvim
per the above configuration.main.tf
with the above content.terraform init
as required byterraform-ls
.main.tf
file to letterraform-ls
initialize.terraform-ls
either runningterraform-ls
with-log-file
or using the:CocInfo
Vim/Neovim command.The text was updated successfully, but these errors were encountered: