Skip to content

Fix #148 Add Redis::CommandError handling - #160

Merged
leandromoreira merged 3 commits into
leandromoreira:mainfrom
corsonknowles:fix-issues-148-124-lua-script-reload-error-handling
Jan 27, 2026
Merged

Fix #148 Add Redis::CommandError handling#160
leandromoreira merged 3 commits into
leandromoreira:mainfrom
corsonknowles:fix-issues-148-124-lua-script-reload-error-handling

Conversation

@corsonknowles

Copy link
Copy Markdown
Contributor

Redlock 2.0+ mostly supports object instantiation, except for this edge case.

See:

Aside from causing difficulties while upgrading, this limits the use of certain functionality.

I tried to be careful in error handling here that the error class is defined and loaded. This is an extension of the solution offered here:

Added a spec context for good measure.

@corsonknowles

Copy link
Copy Markdown
Contributor Author

@jakephot - since this is essentially your solution re-wrapped, I wonder if you have any comments

@leandromoreira

Copy link
Copy Markdown
Owner

that's amazing @corsonknowles thank you! can you add the ostruct to Gemfile or gemspec so we can see the tests running.

@corsonknowles
corsonknowles force-pushed the fix-issues-148-124-lua-script-reload-error-handling branch from 5eccb15 to 08800d7 Compare January 26, 2026 02:12
@corsonknowles

corsonknowles commented Jan 26, 2026

Copy link
Copy Markdown
Contributor Author

that's amazing @corsonknowles thank you! can you add the ostruct to Gemfile or gemspec so we can see the tests running.

I pushed that up and then found

So switched to address it that way.

@jakephot

Copy link
Copy Markdown

@corsonknowles Looks great! I'm excited to upgrade to 2.x.x finally.

@leandromoreira

Copy link
Copy Markdown
Owner

I like the reborn but prefer rebirth 😆 just kidding, it seems we are still pointing to coveralls Failure/Error: require 'coveralls'

… coveralls dependency that was still pulling ostruct
@corsonknowles

Copy link
Copy Markdown
Contributor Author

I think it's still called that, but I had failed to update the json version, so it was still requiring ostruct transitively from the older version. Updated json version as well and everything's running locally

@leandromoreira

Copy link
Copy Markdown
Owner

I think we'll drop support to 2.5 and 2.6 which should be fine, they are EOL anyways.

@leandromoreira

Copy link
Copy Markdown
Owner

thank you so much @corsonknowles

@leandromoreira
leandromoreira merged commit 3d4a8d2 into leandromoreira:main Jan 27, 2026
0 of 7 checks passed
@leandromoreira

Copy link
Copy Markdown
Owner
image

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

Successfully merging this pull request may close these issues.

3 participants