Skip to content

invalid value (nil) at index 285 in table for 'concat' #19

@meisuj815

Description

@meisuj815

error:

 [error] 6280#6280: *962711 lua entry thread aborted: runtime error: /usr/local/openresty/lualib/resty/shell.lua:136: invalid value (nil) at index 2 in table for 'concat'
stack traceback:
coroutine 0:
        [C]: in function 'concat'
        /usr/local/openresty/lualib/resty/shell.lua:139: in function 'run'

code:

        local shell = require "resty.shell"

        local stdin = nil
        local timeout = 10000  -- ms
        local max_size = 40960  -- byte

        local ok, stdout, stderr, reason, status =
            shell.run([[curl https://blockchain.info/q/getreceivedbyaddress/123]], stdin, timeout, max_size)

since that is a error output(ok == nil) now I just edit the stdout and stderr to nil in shell.lua;

...
136         local stdout = nil
137         release_tab(tab_pool_tag, stdout_tab)
138
139         local stderr = nil
140         release_tab(tab_pool_tag, stderr_tab)
...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions