splix / grails-spring-security-facebook

Facebook Authentication plugin for Grails
http://splix.github.io/grails-spring-security-facebook/index.html
Other
39 stars 35 forks source link

FacebookAuthProvider Can't fetch access_token for code #81

Open moniman opened 9 years ago

moniman commented 9 years ago

Hi,

Sometimes I see that errors in my logs. I can't understand why. Have you an idea ?

grails 2.4.4 java 8 spring-security-facebook:0.17 spring-security-core:2.0-RC4

2015-02-03 16:49:18 facebook.FacebookAuthProvider Can't fetch access_token for code '********'
2015-02-03 16:49:18 errors.GrailsExceptionResolver NullPointerException occurred when processing request: [GET] /
Cannot get property 'metaClass' on null object. Stacktrace follows:
org.codehaus.groovy.grails.web.pages.exceptions.GroovyPagesException: Error processing GroovyPageView: Error executing tag <g:applyLayout>: Error executing tag <g:render>: Cannot get property 'metaClass' on null object
    at grails.plugin.cache.web.filter.PageFragmentCachingFilter.doFilter(PageFragmentCachingFilter.java:198)
    at grails.plugin.cache.web.filter.AbstractFilter.doFilter(AbstractFilter.java:63)
    at grails.plugin.springsecurity.web.filter.GrailsAnonymousAuthenticationFilter.doFilter(GrailsAnonymousAuthenticationFilter.java:53)
    at grails.plugin.springsecurity.web.authentication.RequestHolderAuthenticationFilter.doFilter(RequestHolderAuthenticationFilter.java:49)
    at com.the6hours.grails.springsecurity.facebook.FacebookAuthRedirectFilter.doFilter(FacebookAuthRedirectFilter.groovy:46)
    at grails.plugin.springsecurity.web.authentication.logout.MutableLogoutFilter.doFilter(MutableLogoutFilter.java:82)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    at java.lang.Thread.run(Thread.java:745)
Caused by: org.codehaus.groovy.grails.web.taglib.exceptions.GrailsTagException: Error executing tag <g:applyLayout>: Error executing tag <g:render>: Cannot get property 'metaClass' on null object
    at gsp_myapp_homeindex_gsp.run(gsp_myapp_homeindex_gsp.groovy:346)
    ... 9 more
Caused by: org.codehaus.groovy.grails.web.taglib.exceptions.GrailsTagException: Error executing tag <g:render>: Cannot get property 'metaClass' on null object
    at gsp_myapp_layoutsmain_gsp$_run_closure2.doCall(gsp_myapp_layoutsmain_gsp.groovy:69)
    at gsp_myapp_layoutsmain_gsp.run(gsp_myapp_layoutsmain_gsp.groovy:111)
    ... 10 more
Caused by: java.lang.NullPointerException: Cannot get property 'metaClass' on null object
    at grails.plugin.springsecurity.SecurityTagLib.determineSource(SecurityTagLib.groovy:264)
    at grails.plugin.springsecurity.SecurityTagLib$_closure4.doCall(SecurityTagLib.groovy:105)
    at gsp_myapp_menu_navbar_gsp.run(gsp_myapp_menu_navbar_gsp.groovy:14)
    ... 12 more
2015-02-03 16:49:24 facebook.FacebookAuthProvider Can't fetch access_token for code '********'
2015-02-03 16:49:24 errors.GrailsExceptionResolver NullPointerException occurred when processing request: [GET] /
Cannot get property 'metaClass' on null object. Stacktrace follows:
org.codehaus.groovy.grails.web.pages.exceptions.GroovyPagesException: Error processing GroovyPageView: Error executing tag <g:applyLayout>: Error executing tag <g:render>: Cannot get property 'metaClass' on null object
    at grails.plugin.cache.web.filter.PageFragmentCachingFilter.doFilter(PageFragmentCachingFilter.java:198)
    at grails.plugin.cache.web.filter.AbstractFilter.doFilter(AbstractFilter.java:63)
    at grails.plugin.springsecurity.web.filter.GrailsAnonymousAuthenticationFilter.doFilter(GrailsAnonymousAuthenticationFilter.java:53)
    at grails.plugin.springsecurity.web.authentication.RequestHolderAuthenticationFilter.doFilter(RequestHolderAuthenticationFilter.java:49)
    at com.the6hours.grails.springsecurity.facebook.FacebookAuthRedirectFilter.doFilter(FacebookAuthRedirectFilter.groovy:46)
    at grails.plugin.springsecurity.web.authentication.logout.MutableLogoutFilter.doFilter(MutableLogoutFilter.java:82)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    at java.lang.Thread.run(Thread.java:745)
Caused by: org.codehaus.groovy.grails.web.taglib.exceptions.GrailsTagException: Error executing tag <g:applyLayout>: Error executing tag <g:render>: Cannot get property 'metaClass' on null object
    at gsp_myapp_homeindex_gsp.run(gsp_myapp_homeindex_gsp.groovy:346)
    ... 9 more
Caused by: org.codehaus.groovy.grails.web.taglib.exceptions.GrailsTagException: Error executing tag <g:render>: Cannot get property 'metaClass' on null object
    at gsp_myapp_layoutsmain_gsp$_run_closure2.doCall(gsp_myapp_layoutsmain_gsp.groovy:69)
    at gsp_myapp_layoutsmain_gsp.run(gsp_myapp_layoutsmain_gsp.groovy:111)
    ... 10 more
Caused by: java.lang.NullPointerException: Cannot get property 'metaClass' on null object
    at grails.plugin.springsecurity.SecurityTagLib.determineSource(SecurityTagLib.groovy:264)
    at grails.plugin.springsecurity.SecurityTagLib$_closure4.doCall(SecurityTagLib.groovy:105)
    at gsp_myapp_menu_navbar_gsp.run(gsp_myapp_menu_navbar_gsp.groovy:14)
    ... 12 more
ptoner commented 9 years ago

I get the same thing. It's semi-often.

martinduris commented 8 years ago

Same here.

When running app localy - development - it works 100% alright. But when i upload it into server :

can someone help pls ?