question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Plugin treats inner quotes as syntax errors

See original GitHub issue

When trying to use inner quotes inside of an interpolation block the plugin treats it as a syntax error. This functionality was added in Terraform 0.7 as per this PR.

stage = "${replace("%{stageVariables.stage}", "%", "$")}"

Prerequisites

  • [√] Ensure you have latest version of plugin installed
  • [√] Search for possible issue duplicates

Installation details

  • [√ ] IDE version
IntelliJ IDEA 2017.1.5
Build #IU-171.4694.70, built on July 4, 2017
Subscription expired on August 24, 2017
JRE: 1.8.0_112-release-736-b21 x86_64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
Mac OS X 10.12.6
  • [√] intellij-hcl plugin version
v0.6.5
  • [√] Terraform version
Terraform v0.10.2

Terraform Configuration Files

stage     = "${replace("%{stageVariables.stage}", "%", "$")}"

Expected Behavior

Inner strings should be treated as such.

Actual Behavior

The plugin treats the inner strings as syntax errors.

Steps to Reproduce

Try to use inner strings inside of an interpolation block.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
hamenocommented, Aug 5, 2018

Ahh, that fixed it. Terraform Config was only used for tfvars somehow

0reactions
VladRassokhincommented, Aug 5, 2018

@hameno Please ensure that file has .tf extension or has language set to Terraform Configuration, not Hashicorp Configuration Language since in the latter injections are not allowed

Read more comments on GitHub >

github_iconTop Results From Across the Web

PHP parse/syntax errors; and how to solve them
The most prevalent newcomer mistakes are: Missing semicolons ; for terminating statements/lines. Mismatched string quotes for " or ' and unescaped ...
Read more >
[HELP] RNG Quote Bot - Syntax Error : r/learnjavascript - Reddit
I am trying to build a program that will spit out a randomly generated quote. const { SlashCommandBuilder } = require('@discordjs/builders')…
Read more >
Preprocess file raises syntax errors when source file contains ...
A preprocessed file raises syntax errors when the original source file contains hard-coded strings with two consecutive single or double quotes.
Read more >
quote - Rust - Docs.rs
This crate provides the quote! macro for turning Rust syntax tree data structures ... The idea of quasi-quoting is that we write code...
Read more >
Upgrading your build from Gradle 7.x to the latest
Some plugins will break with this new version of Gradle, for example because they use internal APIs that have been removed or changed....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found