VerifyError; Expecting a stack map frame in method controllers.Secure$Security.authentify

Viewed 8859

I followed the tutorial introducing the Play framework, but it gives me an error:

Execution exception VerifyError occured : Expecting a stack map frame in method controllers.Secure$Security.authentify(Ljava/lang/String;Ljava/lang/String;)Z at offset 33

I'm not sure what I did wrong. The code I'm using (snippets):

package controllers;

..

@With(Secure.class)
public class Application extends Controller 
{
    @Before
    public static void setConnectedUser() 
    {
        if (Security.isConnected()) 
        {
            User user = User.find("byEmail", Security.connected()).first();
            user.password = null;
            renderArgs.put("user", user);
        }
    }

    ...

For the Security class:

package controllers;

import models.*;

public class Security extends Secure.Security {    
    static boolean authenticate(String username, String password) {
        return User.connect(username, password) != null;
    }
}

I also added the secure module to dependencies.yml which loads correctly after restarting Play framework. I added the secure model to my routes. Eclipse gives no errors; error only occurs on execution time. The Secure.Security class does actually have the public static isConnected method available. I'm using the most recent version for the Play framework (1.2.2).

5 Answers
Related