beanstalkd / beanstalkd/beaneater

Using Hash#slice forces ruby 2.5+

Open
#83 4 comments 0 reactions 0 assignees View on GitHub
Dominant language
Ruby
Stars
201
Forks
45
PR merge metrics
No merged PRs in 30d

Description

The slice method was added in ruby 2.5+. On ruby 2.3 it causes this error:
```
NoMethodError: undefined method `slice' for {}:Hash
/var/lib/gems/2.3.0/gems/beaneater-1.1.1/lib/beaneater/connection.rb:73:in `transmit'
/var/lib/gems/2.3.0/gems/beaneater-1.1.1/lib/beaneater/tube/collection.rb:33:in `transmit'
/var/lib/gems/2.3.0/gems/beaneater-1.1.1/lib/beaneater/tube/collection.rb:79:in `all'
```

If that's deliberate, ok, but I would expect explicit mention on README. If it's not (and seems it's only slice in whole code), you may want to re-think https://github.com/beanstalkd/beaneater/commit/13e97917f1bd9db92fa3e0c0c7af1227784995bd

Contributor guide

No contributing guide indexed for this repository

Research direction

Start at lib/beaneater/connection.rb line 73 and inspect the referenced commit that introduced Hash#slice. Check the README for the documented Ruby requirement. Done means either Ruby 2.3 no longer raises this error or the README explicitly states the Ruby 2.5+ requirement.

Written by the indexing model from the issue text.

Assessment

Tech stack
ruby
Domain
backend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.