# Parse error, unexpected $, expecting kEND instantrails

**URL:** <https://www.ruby-forum.com/t/parse-error-unexpected-expecting-kend-instantrails/74040>\
**Category:** Ruby\
**Created:** [October 29, 2006, 11:42am UTC](https://www.ruby-forum.com/t/parse-error-unexpected-expecting-kend-instantrails/74040 "2006-10-29T11:42:47Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![rajug](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/9f8e36/32.png) [@rajug](https://www.ruby-forum.com/u/rajug)\
**Post date:** [October 29, 2006, 11:42am UTC](https://www.ruby-forum.com/t/parse-error-unexpected-expecting-kend-instantrails/74040/1 "2006-10-29T11:42:47Z")

</div>

I have come to this “parse error, unexpected $, expecting kEND” error  
while attempting to implement the Heatmap (ruby and javascript) on one  
of my project. I did my lots of tried using different versions of  
ruby/instantrails package but could not overcome this error.  
Please suggest me anyone how can i implement the heatmap in my site  
using ruby.  
With Regards  
Raju Gautam

---

<div class="post-metadata">

**Author:** ![rajug](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/9f8e36/32.png) [@rajug](https://www.ruby-forum.com/u/rajug)\
**Post date:** [October 29, 2006, 12:36pm UTC](https://www.ruby-forum.com/t/parse-error-unexpected-expecting-kend-instantrails/74040/2 "2006-10-29T12:36:42Z")

</div>

Raju Gautam wrote:

> I have come to this “parse error, unexpected $, expecting kEND” error  
> while attempting to implement the Heatmap (ruby and javascript) on one  
> of my project. I did my lots of tried using different versions of  
> ruby/instantrails package but could not overcome this error.  
> Please suggest me anyone how can i implement the heatmap in my site  
> using ruby.

You have a syntax error probably missing a matching “end”.

$ ruby -c -w -e ‘class Foo; def bar() end’  
-e:1: parse error, unexpected $, expecting kEND

You probably want to use an editor that does syntax highlighting to find  
the missing piece. Code beautifiers often help also.

Regards

```
robert
```
