[TxMt] Re: Bug report: Ruby error when running "Comment Line" in some Terraform documents

Allan Odgaard mailinglist at textmate.org
Sun Mar 5 04:18:46 UTC 2017


On 3 Mar 2017, at 3:48, Alex Chan wrote:

> I’ve hit a bug when using “Comment Line” in Terraform documents,
> although it only occurs on certain lines.
> […]
> a) Comment Line:140:in `<main>': undefined method `to_a' for
> "\u0000variable \"aws_region\" {":String (NoMethodError)

It seems that your _Comment Line_ action is being executed by ruby 2.0, 
however, the shebang of this command is: `#!/usr/bin/env ruby18`.

I think it fails only for some lines because `to_a` is only used for 
certain code paths.

Can you double-check that you are using the stock/unmodified _Comment 
Line_ action?

One way to do this would be to use ⌃⌘T then switch to Key Equivalent 
search and press ⌘/ — now hit “Edit” and check you get the 
command in the Source bundle, and that it has the `ruby18` shebang.

Kind regards Allan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macromates.com/textmate/attachments/20170305/f8694422/attachment.html>


More information about the textmate mailing list