tmolitor-stud-tu / mod_push_appserver

Simple and extendable appserver for XMPP pushes (aka. XEP-0357)
MIT License
25 stars 9 forks source link

Error initializing module 'push_appserver_fcm' #8

Closed streaps closed 5 years ago

streaps commented 5 years ago

I'm getting the following error with Prosody 0.11.1. Any idea what I can do to fix it?

Dec 24 21:50:20 modulemanager   error   Error initializing module 'push_appserver_fcm' on 'localhost': /usr/share/lua/5.2/ltn12.lua:
16: Attempt to set a global: ltn12 = table: 0x55cb45f25190
stack traceback:
        [C]: in function 'error'
        /usr/lib/prosody/util/startup.lua:336: in function '__newindex'
        /usr/share/lua/5.2/ltn12.lua:16: in main chunk
        [C]: in function '_real_require'
        /usr/lib/prosody/util/startup.lua:141: in function 'require'
        /usr/share/lua/5.2/ssl/https.lua:11: in main chunk
        [C]: in function '_real_require'
        /usr/lib/prosody/util/startup.lua:141: in function 'require'
        ...server/mod_push_appserver_fcm/mod_push_appserver_fcm.lua:12: in main chunk
        [C]: in function 'xpcall'
        /usr/lib/prosody/core/modulemanager.lua:178: in function 'do_load_module'
        /usr/lib/prosody/core/modulemanager.lua:256: in function 'load'
        /usr/lib/prosody/core/modulemanager.lua:78: in function '?'
        /usr/lib/prosody/util/events.lua:79: in function </usr/lib/prosody/util/events.lua:75>
        (...tail calls...)
        /usr/lib/prosody/core/hostmanager.lua:108: in function 'activate'
        /usr/lib/prosody/core/hostmanager.lua:58: in function '?'
        /usr/lib/prosody/util/events.lua:79: in function </usr/lib/prosody/util/events.lua:75>
        (...tail calls...)
        /usr/lib/prosody/util/startup.lua:327: in function 'prepare_to_start'
        /usr/lib/prosody/util/startup.lua:548: in function 'f'
        /usr/lib/prosody/util/async.lua:139: in function 'func'
        /usr/lib/prosody/util/async.lua:127: in function </usr/lib/prosody/util/async.lua:125>
Dec 24 21:50:20 localhost:push_appserver        info    Appserver started at URL: <http://localhost:5280/push_appserver/>
tmolitor-stud-tu commented 5 years ago

LuaSocket tries to pollute the global scope but prosody prevents this, see my next commit hopefully containing a fix for this :)