Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

3.0.0: nakama/socket.lua:18: attempt to call global 'log' (a nil value) #43

Closed
logicalparadox opened this issue Apr 11, 2022 · 1 comment · Fixed by #44
Closed

3.0.0: nakama/socket.lua:18: attempt to call global 'log' (a nil value) #43

logicalparadox opened this issue Apr 11, 2022 · 1 comment · Fixed by #44

Comments

@logicalparadox
Copy link

Reproduce by receiving a socket event that does not have a bound listener.

ERROR:SCRIPT: nakama/socket.lua:18: attempt to call global 'log' (a nil value)
stack traceback:
  nakama/socket.lua:18: in function on_message
  nakama/engine/defold.lua:122: in function on_message
  nakama/engine/defold.lua:164: in function <nakama/engine/defold.lua:152>
@britzl
Copy link
Collaborator

britzl commented Apr 11, 2022

Thank you for the report @logicalparadox. And sorry about this. I encountered this problem myself and by accident made the fix in the generated code instead of in the template. And the fix got overwritten when the code was generated next time.

In the coming weeks I'll add unit tests to catch issues such as this one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants