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

runtime error(ctx.lua): bad argument #2 to 'setmetatable' (nil or table expected) #3171

Closed
zmeng9 opened this issue Dec 31, 2020 · 6 comments

Comments

@zmeng9
Copy link

zmeng9 commented Dec 31, 2020

Issue description

I had the same error as issue #3079 while debugging my program, and then I fixed the bug with pr #3105, but this error happened.

image
image

image

Environment

  • apisix version: 2.1
  • OS: Linux
  • Nginx version: openresty / 1.19.3.1
@zmeng9 zmeng9 changed the title runtime error(ctx.lua): bad argument #2 to 'setmetatable' (nil or table expected) runtime error(ctx.lua): bad argument #2 to 'setmetatable' (nil or table expected) Dec 31, 2020
@spacewander
Copy link
Member

Will you add a log in ctx.lua:83 to see what is passed to setmetatable?

@zmeng9
Copy link
Author

zmeng9 commented Jan 4, 2021

image

@spacewander
Copy link
Member

Can you confirm if this change: https://github.com/apache/apisix/pull/3182/files solve your problem?

@zmeng9
Copy link
Author

zmeng9 commented Jan 4, 2021

Yes, thx.

@Hcreak
Copy link

Hcreak commented Jan 4, 2021

@spacewander
I want to know will this bug be corrected in the next release?
I’m suffering from this problem now. L O L~

@spacewander
Copy link
Member

We will get it merged once @membphis is back.

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

3 participants