Playback Error 2.1: Cannot Find Character Error

My controller has the following:

public static Result index() {
    return ok(indexpage.render());
}

my page is indexpage.scala.html,

@main("Test") {

}

but Play 2.1 gives me the following error: error: cannot find character

Screenshothot of error

Any ideas?

EDIT: I created another view + method in my controller, had the same exact error.

+4
source share
2 answers

A problem was detected when I cleaned up my import, which I accidentally deleted

import views.html.*;

from my controller class. I would have posted the answer earlier, but for some reason people with less than 10 reputations should wait 8 hours before answering the question that they made.

+6
source

In my case, as soon as I cleaned the project, it worked again

activator clean
activator run
+1

All Articles