Skip to content

hcl2cdk: getExpressionAst fails with regex strings due to escaping #2910

Open
@sentry-io

Description

@sentry-io

Sentry Issue: CDKTF-REGISTRY-DOCS-7P

Error: getExpressionAst errors on input string '"^myami-\d{3}"': main.tf:0,8-10: Invalid escape sequence; The symbol "d" is not a valid escape sequence selector. 
  File "/__t/node/18.16.0/x64/lib/node_modules/cdktf-registry-docs/node_modules/@cdktf/hcl2json/lib/bridge.js", line 81, in cb
    err ? reject(new Error(err)) : resolve(...msg);
  File "/__t/node/18.16.0/x64/lib/node_modules/cdktf-registry-docs/node_modules/@cdktf/hcl2json/wasm/wasm_exec.js", line 366, in syscall/js.valueInvoke
    const result = Reflect.apply(v, undefined, args);
  File "wasm://wasm/018549f2:wasm-function[1489]", in <anonymous>
  File "wasm://wasm/018549f2:wasm-function[1473]", in <anonymous>
  File "wasm://wasm/018549f2:wasm-function[3125]", in <anonymous>
...
(5 additional frame(s) were not displayed)

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingfeature/convertpriority/important-longtermMedium priority, to be worked on within the following 1-2 business quarters.size/mediumestimated < 1 week

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions