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

error: .../modules/lua-resty-dns-master/lib/resty/dns/resolver.lua:92: attempt to call local 'new_tab' (a table value) #34

Open
ilham9649 opened this issue Jan 18, 2018 · 1 comment

Comments

@ilham9649
Copy link

ilham9649 commented Jan 18, 2018

hi, when I try to use this module it got me this error:
nginx: [error] init_by_lua error: .../modules/lua-resty-dns-master/lib/resty/dns/resolver.lua:92: attempt to call local 'new_tab' (a table value)
stack traceback:
.../modules/lua-resty-dns-master/lib/resty/dns/resolver.lua:92: in main chunk
[C]: in function 'require'
init_by_lua:2: in main chunk

the configuration that I use in nginx.conf is :
lua_package_path "/etc/nginx/modules/lua-resty-dns-master/lib/resty/dns/resolver.lua";

Is there something that I doing wrong? Thanks.

Update: is it need to use lua 5.2.3? because my current lua version is 5.1.4

Update: this issues is resolved by not using require "resty.dns.resolver" in init_by_lua_block. THanks

@agentzh
Copy link
Member

agentzh commented Jan 19, 2018

@ilham9649 It seems that you have a 3rd-party Lua module named table.new in your system's Lua module search paths. You should remove it from the search paths.

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

No branches or pull requests

2 participants