[#83096] File.setuid? on IO (Re: [ruby-cvs:67289] normal:r60108 (trunk): file.c: release GVL in File.{setuid?, setgid?, sticky?}) — Nobuyoshi Nakada <nobu@...>
On 2017/10/04 8:47, [email protected] wrote:
5 messages
2017/10/04
[#83100] Re: File.setuid? on IO (Re: [ruby-cvs:67289] normal:r60108 (trunk): file.c: release GVL in File.{setuid?, setgid?, sticky?})
— Eric Wong <normalperson@...>
2017/10/04
Nobuyoshi Nakada <[email protected]> wrote:
[#83105] Re: File.setuid? on IO (Re: [ruby-cvs:67289] normal:r60108 (trunk): file.c: release GVL in File.{setuid?, setgid?, sticky?})
— Nobuyoshi Nakada <nobu@...>
2017/10/04
On 2017/10/04 15:55, Eric Wong wrote:
[#83107] Alias Enumerable#include? to Enumerable#includes? — Alberto Almagro <albertoalmagro@...>
Hello,
9 messages
2017/10/04
[#83113] Re: Alias Enumerable#include? to Enumerable#includes?
— "Urabe, Shyouhei" <shyouhei@...>
2017/10/05
This has been requested countless times, then rejected each and every time.
[#83129] Re: Alias Enumerable#include? to Enumerable#includes?
— Alberto Almagro <albertoalmagro@...>
2017/10/05
Sorry I didn't found it on the core mail list's archive.
[#83138] Re: Alias Enumerable#include? to Enumerable#includes?
— "Urabe, Shyouhei" <shyouhei@...>
2017/10/06
Ruby has not been made of popular votes so far. You have to show us
[#83149] Re: Alias Enumerable#include? to Enumerable#includes?
— Eric Wong <normalperson@...>
2017/10/06
Alberto Almagro <[email protected]> wrote:
[#83200] [Ruby trunk Feature#13996] [PATCH] file.c: apply2files releases GVL — normalperson@...
Issue #13996 has been reported by normalperson (Eric Wong).
4 messages
2017/10/10
[ruby-core:83298] [Ruby trunk Bug#14017] Hash.sort_by inconsistent between 2.2.6 and upper versions
From:
cardoso_tiago@...
Date:
2017-10-15 17:11:36 UTC
List:
ruby-core #83298
Issue #14017 has been updated by chucke (Tiago Cardoso).
got it, forgot to check the doc. Thx for clearing that up!
----------------------------------------
Bug #14017: Hash.sort_by inconsistent between 2.2.6 and upper versions
https://bugs.ruby-lang.org/issues/14017#change-67257
* Author: chucke (Tiago Cardoso)
* Status: Rejected
* Priority: Normal
* Assignee:
* Target version:
* ruby -v: 2.2.6
* Backport: 2.3: UNKNOWN, 2.4: UNKNOWN
----------------------------------------
The bug occurs when sorting by a numeric value and two different keys have similar values: It is very easily demonstrated here:
```ruby
enc = {"foo"=>0.9, "bar"=>1.0, "identity"=>1.0}
enc.sort_by { |_, q| -q }
# in ruby 2.2.6
#=> [["identity", 1.0], ["bar", 1.0], ["foo", 0.9]]
# in rubies > 2.2
#=> [["bar", 1.0], ["identity", 1.0], ["foo", 0.9]]
```
For the record, newer rubies present the correct version IMO, as the order of equivalent values shouldn't be changed based on the same value.
I looked at the [ruby 2.3 release notes](https://github.com/ruby/ruby/blob/v2_3_0/NEWS), but couldn't find the mention to a fix, so I can't say that this is a "behaviour change, upgrade to new" case. What I can say is that this behaviour seems to have changed in ruby 2.3 (tested also with ruby 2.2.2 and ruby 2.1.9 and can reproduce the same result as with 2.2.6).
As an example of production code which is probably returning a wrong result is rack, which [uses as variation of this to select the best content encoding](https://github.com/rack/rack/blob/911c4fe15e3e57d44ac891c0cbabbf44bdf71201/lib/rack/utils.rb#L188) .
Is this something which can be backported into a possible 2.2.7, or is ruby 2.2 in maintenance mode?
--
https://bugs.ruby-lang.org/
Unsubscribe: <mailto:[email protected]?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>