timgit / pg-boss

Queueing jobs in Postgres from Node.js like a boss
MIT License
1.95k stars 153 forks source link

Typo in validation for Postgres names #457

Closed eloff closed 1 month ago

eloff commented 1 month ago

assert(!/^d/.test(name), 'Name cannot start with a number')

You mean \d. I had a name that started with a d, and the error took me a while to figure out.

https://github.com/timgit/pg-boss/blob/10.0.0-beta2/src/attorney.js#L182

EvertEt commented 1 month ago

A fix for this has been merged in https://github.com/timgit/pg-boss/pull/455 but not published yet

timgit commented 1 month ago

This has been published in the latest beta tag

eloff commented 1 month ago

This has been published in the latest beta tag

Oh, I see. There's only up to beta2 in tags in this repo, but beta5 is the latest on npm. That threw me.