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

Lua redis() command arguments must be strings or integers #1351

Closed
imomin opened this issue Aug 4, 2022 · 3 comments
Closed

Lua redis() command arguments must be strings or integers #1351

imomin opened this issue Aug 4, 2022 · 3 comments

Comments

@imomin
Copy link

imomin commented Aug 4, 2022

I am getting below error, it is random. I can't seem to isolate the issue. Any help is appreciated.
I believe it is happening when Queue.add() is called.'
There an issue created #72 back in 2109 but it was resolved with fix. Not sure if this is related to opts.maxLenEvents.

/Users/mac/Documents/projects/app/node_modules/redis-parser/lib/parser.js:179
    return new ReplyError(string)
           ^

ReplyError: ERR Error running script (call to f_82d7fd1e2c160592bc98d0599e216fa9f80e3949): @user_script:153: @user_script: 153: Lua redis() command arguments must be strings or integers
    at parseError (/Users/mac/Documents/projects/app/node_modules/redis-parser/lib/parser.js:179:12)
    at parseType (/Users/mac/Documents/projects/app/node_modules/redis-parser/lib/parser.js:302:14) {
  command: {
    name: 'evalsha',
    args: [
      '82d7fd1e2c160592bc98d0599e216fa9f80e3949',
      '9',
      'bull:textParser:wait',
      'bull:textParser:paused',
      'bull:textParser:meta',
      'bull:textParser:id',
      'bull:textParser:delayed',
      'bull:textParser:priority',
      'bull:textParser:completed',
      'bull:textParser:events',
      'bull:textParser:delay',
      Buffer(33) [Uint8Array] [
        152, 176,  98, 117, 108, 108,  58,
        116, 101, 120, 116,  80,  97, 114,
        115, 101, 114,  58, 160, 192, 203,
         66, 120,  38, 106, 211, 110, 112,
          0, 192, 192, 192, 192
      ],
      '{"id":"atoz","name":"v1_atoz","author":"as87d","title":"What do you think about it?","link_id":"l1_a8sd7","url":"https://www.example.org/atoz/#v1_atoz","body_html":"<div class=\\"md\\"><p>That was great!</p>\\n</div>","body_text":"That was great!","created":1659579994}',
      Buffer(54) [Uint8Array] [
        222,   0,   5, 168,  97, 116, 116, 101, 109, 112,
        116, 115,   0, 165, 100, 101, 108,  97, 121,   0,
        176, 114, 101, 109, 111, 118, 101,  79, 110,  67,
        111, 109, 112, 108, 101, 116, 101,  10, 165, 106,
        111,  98,  73, 100, 192, 167,  98,  97,  99, 107,
        111, 102, 102, 192
      ]
    ]
  }
}
@imomin
Copy link
Author

imomin commented Aug 4, 2022

Closing the issue.
Looks like there was a typo in the job name variable (Queue.add(typo, data)) and all the jobs might be getting created as undefined as job name.

@imomin imomin closed this as completed Aug 4, 2022
@arjunmehta
Copy link

This seems like an error that should be caught. Why would you defer to the obscure Lua error when there should be a check on the Job name validity?

@manast
Copy link
Contributor

manast commented Mar 5, 2024

Yeah, that is the question, defensive programming vs letting the compiler do its job... I tend to like more the second alternative.

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