Project

General

Profile

Activity

From 09/17/2018 to 09/23/2018

09/23/2018

11:16 PM Bug #15152 (Closed): Thread Crashes
When I run my rails test suite with the parallel_test gem a thread crashes. The test suite completely passes when I don't run the tests in parallel and it also works fine when I run unit tests in parallel, but if I run enough system test... Durrell (Durrell Chamorro)
03:27 PM Feature #15151 (Open): String#slice!(0,..) creates a duplicate of original string
String#slice! when used at beginning of string (e.g. slice!(0,10)) calls rb_str_drop_bytes which creates shared string for non embedded string. str_modify_keep_cr clears the flag of shared string which is called before rb_str_drop_bytes.... chopraanmol1 (Anmol Chopra)
12:40 PM Revision 85e5424a (git): test_win32api.rb: suppress a warning
* test/test_win32api.rb: suppress a warning, which we know already
well.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64816 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
08:52 AM Bug #15130: Nested Timeouts hang on cygwin
duerst@it.aoyama.ac.jp wrote:
>
> Please tell me what I can do to help you solve this problem.

Oops, I guess pthread_kill isn't going to work in cygwin :x

This brings the Cygwin pthreads timer thread closer to what was
in 2.5 ...
normalperson (Eric Wong)
08:04 AM Bug #14807: 2.6.0-preview2 segfaults on OpenBSD due to missing pthread_condattr_init call
> https://bugs.ruby-lang.org/issues/14807#change-74146

Right, already in trunk at r63548

And back to Jeremy's earlier comment:
> It's defined but I don't think it would be usable:
>
> /usr/include/pthread.h:#define PTHREAD_CON...
normalperson (Eric Wong)
02:35 AM Bug #13167: Dir.glob is 25x slower since Ruby 2.2
After this commit is merged, some CIs that has -DVM_CHECK_MODE=2 and continue to test latest revision started to randomly crash "TestGem#test_load_plugins":
http://ci.rvm.jp/results/trunk-asserts@silicon-docker
http://ci.rvm.jp/results...
k0kubun (Takashi Kokubun)

09/22/2018

11:52 PM Revision ae0e98ce (git): Skip a cleanup if new_ole failed
On Appveyor, WIN32OLE sometimes fails due to a system shutdown, and
`@ie` is not assigned.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64815 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
09:57 PM Feature #15149 (Open): extend string format to nil safe
I'd like to suggest a new modifier for the string format
(aka the printf-style format string)
## Examples
### Current
~~~
'%s' % nil => ''
'%d' % nil => Exception: TypeError: can't convert nil into Integer
~~~
### Suggestio...
foonlyboy (Eike Dierks)
08:46 PM Bug #15148 (Rejected): String::instance_methods size is different String#methods size after call pp method
nobu (Nobuyoshi Nakada)
06:14 PM Bug #15148 (Rejected): String::instance_methods size is different String#methods size after call pp method
I'm sorry, my English is poor.i'm sorry i find this is not a bug, please help me close this issue,
Anonymous
08:39 PM Revision 04a353fe (git): tool/enc-unicode.rb: rewrote without flip-flop
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64814 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
08:13 PM Revision 450107ef (git): * 2018-09-23
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64813 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
08:13 PM Revision 55c7b854 (git): Fix for old names of mcontext registers
c.f. https://github.com/mistydemeo/tigerbrew/issues/473
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64812 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
06:08 PM Bug #14807: 2.6.0-preview2 segfaults on OpenBSD due to missing pthread_condattr_init call
Hi,
The similar problem occurs on NetBSD 8.0_STABLE. (And I belive it would be occur on 7.2.)
`PTHREAD_COND_INITIALIZER` is for `pthread_cond_t` not for `pthread_condattr_t`.
So, initializing `condattr_mono` (via `condattr_monoto...
taca (Takahiro Kambe)
05:11 PM Bug #15147 (Third Party's Issue): Mac OSX (brew) reported: You may have encountered a bug in the Ruby interpreter or extension libraries
running: brew update --verbose on my Mac. Note: brew doctor seems to have a similar error. The runtime asked me to report this to you folks, so I am.
==> Checking dependents for broken library links
/usr/local/Homebrew/Librar...
unixwizard (Clement Cole)
03:31 PM Bug #15146 (Closed): [PATCH] webrick: raise EOFError in parse when read line is nil
If the IO object being read during parse returned `nil` from `gets`, a NoMethodError would be raised calling `bytesize` on `nil`. Instead, an `EOFError` should be returned. This bug has been present since r14260.
https://github.com/ru...
pushrax (Justin Li)
01:11 AM Bug #13167 (Closed): Dir.glob is 25x slower since Ruby 2.2
Applied in changeset trunk|r64810.
----------
dir.c: performance fix with braces
Braces were expended before ruby_glob0(). This caused to call
replace_real_basename() for same plain patterns repeatedly.
Move blace expansion into glob_h...
Anonymous
01:11 AM Revision 50c16d52 (git): * 2018-09-22
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64811 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
01:11 AM Revision 2a119042 (git): dir.c: performance fix with braces
Braces were expended before ruby_glob0(). This caused to call
replace_real_basename() for same plain patterns repeatedly.
Move blace expansion into glob_helper() in ruby_glob0() to reduce
replace_real_basename() call.
This fix changes th...
h.shirosaki (Hiroshi Shirosaki)
12:06 AM Feature #15145: chained mappings proposal
koenhandekyn (koen handekyn) wrote:
> proposal allow
> ...
Is it possible for you to share your trivial implementation of passing more than one block to a method? :)
It is true that the implementation of something like:
~~~ ruby
...
jeremyevans0 (Jeremy Evans)

09/21/2018

10:57 PM Feature #15144: Enumerator#chain
> Obviously, the effect could be reached with flat_map
I always found that name weird so ... assumingly that it is the same
as .flatten.map, I always used the latter. :-)
(I don't recall flat_map offhand and I happily admit that I...
shevegen (Robert A. Heiler)
07:00 PM Feature #15144 (Closed): Enumerator#chain
I am not sure I am not missing something, but...
```ruby
[1, 2, 3].each.chain([3, 4, 5].each) # => Enumerator
```
...seem to be a useful pattern.
It especially shows itself in case of lazy enumerators, representing several long...
zverok (Victor Shepelev)
10:51 PM Feature #15145: chained mappings proposal
(I think you filed this in the wrong section; right now it is under Bugs, but it looks
like a feature so it should go into
https://bugs.ruby-lang.org/projects/ruby-trunk/issues?set_filter=1&tracker_id=2 )
At any rate, to the sugges...
shevegen (Robert A. Heiler)
07:27 PM Feature #15145 (Open): chained mappings proposal
propsal, have map accept array of method references to make chained mapping simpler with suggestion to implement it to behave like the &. operator so that intermediate nil values just ripple through as nil values
proposal allow
~~...
koenhandekyn (koen handekyn)
05:58 PM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
Thread::Light seems nice. Or how about Thread::Feather? A thread as light as a feather. shan (Shannon Skipper)
02:17 PM Feature #10208 (Closed): Passing block to Enumerable#to_h
yhara (Yutaka HARA)
01:52 PM Revision c61adf51 (git): configure.ac: prepend the wrapper after CPP is set
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64809 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
10:31 AM Revision 0d95805c (git): Suppress more -Wparentheses warnings
[Fix GH-1958]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64808 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
10:19 AM Revision 2def5250 (git): * expand tabs.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64807 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
10:19 AM Revision 7e9ee35f (git): Remove -Wno-parentheses flag.
[Fix GH-1958]
From: Jun Aruga <jaruga@redhat.com>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64806 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
08:53 AM Revision 2617dfa9 (git): Fix sample code [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64805 b2dd03c8-39d4-4d8f-98ff-823fe69b080e znz (Kazuhiro NISHIYAMA)
08:36 AM Bug #14959: Writing a "link_to" method and a "url_helper" with a request parameter under certain "if else" statement in Rails helper crashes with KERN_INVALID_ADDRESS at 0x0000000000000000
The same issue is already marked to backport in #14897.
Please wait for 2.5.2.
nobu (Nobuyoshi Nakada)
08:17 AM Bug #14959: Writing a "link_to" method and a "url_helper" with a request parameter under certain "if else" statement in Rails helper crashes with KERN_INVALID_ADDRESS at 0x0000000000000000
I'm not sure if it's going to be backported to current stable version 2.5 but let me clarify couple things just in case for future.
* This is issue does not depend neither rails nor bootsnap
* Yet another minimal reproducible code to...
ujihisa (Tatsuhiro Ujihisa)
08:34 AM Revision 0744b375 (git): Fix a typo [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64804 b2dd03c8-39d4-4d8f-98ff-823fe69b080e znz (Kazuhiro NISHIYAMA)
08:14 AM Feature #5400: Remove flip-flops in 2.0
I agree with Eric.
It is too annoying to rewrite flip-flop.
A patch for flip-flop I found today is:
```diff
diff --git a/tool/enc-unicode.rb b/tool/enc-unicode.rb
index d953014952..c05d02358c 100755
--- a/tool/enc-unicode.rb
...
nobu (Nobuyoshi Nakada)
07:19 AM Revision 89874314 (git): * properties.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64803 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
07:19 AM Revision d00199a1 (git): darwin-cc: hide ld warnings
* tool/darwin-cc: ld in Apple's recent Xcode warns text-based stub
files, which are probably caused by Apple's broken package.
hide such (and architecture deprecation) warnings during
configuration to pass TRY_LDFLAGS.
git-svn-id:...
nobu (Nobuyoshi Nakada)
06:41 AM Bug #15105 (Closed): `rb_debug_inspector_open` breaks lazy proc optimization
Applied in changeset trunk|r64800.
----------
escape all env properly.
* vm_backtrace.c (rb_debug_inspector_open): escape all env using
`rb_vm_stack_to_heap()` before making bindings.
[Bug #15105]
There is a complicated story of...
ko1 (Koichi Sasada)
06:41 AM Revision 02cb9c93 (git): * remove trailing spaces.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64801 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
06:41 AM Revision ac4b2d99 (git): escape all env properly.
* vm_backtrace.c (rb_debug_inspector_open): escape all env using
`rb_vm_stack_to_heap()` before making bindings.
[Bug #15105]
There is a complicated story of this issue:
Without this patch, IFUNC frame does not escaped. A IFUNC ...
ko1 (Koichi Sasada)
06:30 AM Revision a810a1a7 (git): fix typo.
* vm_exec.h (DEBUG_END_INSN()): use `ec` instead of `th`.
This macro is used when `VMDEBUG > 0`.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64799 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
ko1 (Koichi Sasada)
06:07 AM Bug #15130: Nested Timeouts hang on cygwin
I applied the patch, but got the same problem: I had to use Ctrl-C, and got essentially the same backtrace:
Traceback (most recent call last):
15: from -e:1:in `<main>'
14: from /cygdrive/c/Data/ruby_test_patch_pthre...
duerst (Martin Dürst)
01:30 AM Bug #15130: Nested Timeouts hang on cygwin
normalperson (Eric Wong) wrote:
> Martin: can you try the attached patch? And please commit it if it works.
Thanks a lot for your patch. I'm working on trying it out, but I will only have the results later in my (Japanese) afternoon...
duerst (Martin Dürst)
12:48 AM Bug #15130: Nested Timeouts hang on cygwin
Martin: can you try the attached patch? And please commit it if it works.
```
thread_pthread.c: fall back to UBF_TIMER_PTHREAD for Cygwin
UBF_TIMER_NONE is not useful until we can make all I/O
non-blocking <https://b...
normalperson (Eric Wong)
04:14 AM Feature #14722: python's buffer protocol clone
I agree with this request and filed a similar bug: https://bugs.ruby-lang.org/issues/13767.

dsisnero (Dominic Sisneros)
02:23 AM Feature #15143: Extend `Enumerable#to_h`
nobu (Nobuyoshi Nakada) wrote:
> OK, not only `Enumerable`, but `Array`, `Hash`, `ENV`, `NilClass` and `Struct` too?
Thanks for reminding me about that and implementing it.
sawa (Tsuyoshi Sawada)
02:14 AM Revision e5a3bfb3 (git): Fix a typo [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64798 b2dd03c8-39d4-4d8f-98ff-823fe69b080e znz (Kazuhiro NISHIYAMA)

09/20/2018

10:40 PM Bug #14972: Net::HTTP inconsistently raises EOFError when peer closes the connection
If `@socket.read clen, dest` reads fully `clen` bytes then that seems ok. But if it can read fewer than `clen` bytes, then we should keep reading until we read `clen` bytes or reach EOF. joshc (Josh C)
06:24 PM Revision 9b2cf4fb (git): * properties.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64797 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
06:24 PM Revision 19fe6552 (git): Matrix: Add #reflexive? method. [Fix GH-1730]
Adapted from a patch by Yilo
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64796 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Marc-Andre Lafortune
03:06 PM Feature #15143 (Closed): Extend `Enumerable#to_h`
Applied in changeset trunk|r64794.
----------
Enumerable#to_h with block and so on
[Feature #15143]
nobu (Nobuyoshi Nakada)
12:38 PM Feature #15143: Extend `Enumerable#to_h`
`nil` isn't an `Enumerable`, so it's irrelevant. nobu (Nobuyoshi Nakada)
11:48 AM Feature #15143: Extend `Enumerable#to_h`
OK, not only `Enumerable`, but `Array`, `Hash`, `ENV`, `NilClass` and `Struct` too? nobu (Nobuyoshi Nakada)
07:32 AM Feature #15143: Extend `Enumerable#to_h`
Matz, thanks for confirmation. I am happy with my original proposal. sawa (Tsuyoshi Sawada)
07:27 AM Feature #15143: Extend `Enumerable#to_h`
I don't agree with @mame's idea. The return value from the block should be strictly 2 elements array.
Matz.
matz (Yukihiro Matsumoto)
07:26 AM Feature #15143: Extend `Enumerable#to_h`
I changed my mind when I approved `to_h`.
Matz.
matz (Yukihiro Matsumoto)
07:14 AM Feature #15143: Extend `Enumerable#to_h`
mame (Yusuke Endoh) wrote:
> If the block returns an array whose length is > 2, how does it behave?
> ...
My original proposal is to follow the behaviour of the current `map.{...}.to_h`, which means to raise `ArgumentError: wrong array...
sawa (Tsuyoshi Sawada)
06:54 AM Feature #15143: Extend `Enumerable#to_h`
Sorry that I missed the previous duplicate proposals (I found that I had even commented on one of them, which I had forgotten about). But it looks like four years have passed since then, and the situation has changed perhaps. Or, it may ... sawa (Tsuyoshi Sawada)
06:25 AM Feature #15143: Extend `Enumerable#to_h`
nobu (Nobuyoshi Nakada) wrote:
> Have you changed the mind since #10208?
Or since... #666!
marcandre (Marc-Andre Lafortune)
03:04 AM Feature #15143: Extend `Enumerable#to_h`
If the block returns an array whose length is > 2, how does it behave?
```
%w(aa1 ab2 ba3 bb4).to_h {|s| s.chars }
#=> { "a" => { "a" => "1",
"b" => "2" },
"b" => { "a" => "3",
"b" => "4" }...
mame (Yusuke Endoh)
02:47 AM Feature #15143: Extend `Enumerable#to_h`
Have you changed the mind since #10208? nobu (Nobuyoshi Nakada)
02:41 AM Feature #15143: Extend `Enumerable#to_h`
Sounds reasonable. Accepted.
Matz.
matz (Yukihiro Matsumoto)
02:27 AM Feature #15143: Extend `Enumerable#to_h`
I forgot to mention that people alternatively do:
```ruby
(1..5).each_with_object({}){|x, h| h[x] = x ** 2}
#=> {1=>1, 2=>4, 3=>9, 4=>16, 5=>25}
```
which may be more optimal than calling `map`. The proposed feature also has the...
sawa (Tsuyoshi Sawada)
02:23 AM Feature #15143 (Closed): Extend `Enumerable#to_h`
Often, we call `Array#to_h` to the result of `Enumerable#map`:
```ruby
(1..5).map{|x| [x, x ** 2]}.to_h
#=> {1=>1, 2=>4, 3=>9, 4=>16, 5=>25}
```
I am thinking of a feature to do this in a single method call.
Currently, `Enum...
sawa (Tsuyoshi Sawada)
03:06 PM Revision a64338ce (git): * 2018-09-21
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64795 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
03:06 PM Revision abe75149 (git): Enumerable#to_h with block and so on
[Feature #15143]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64794 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
02:30 PM Revision e76eebd7 (git): Ignore Xcode linker warnings
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64793 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
02:00 PM Feature #10208: Passing block to Enumerable#to_h
So, exactly the same proposal linked above got accepted. The name wasn't actually a problem!
Well, congratulations anyway! 😆
knu (Akinori MUSHA)
09:41 AM Misc #15136: Fix -Wparentheses warnings
> I will update and rebase my pull-request for the way.
I updated and rebased my pull-request now!
You can pick up and merge a part of the pull-request, if you like it.
jaruga (Jun Aruga)
08:31 AM Misc #15136: Fix -Wparentheses warnings
> IIRC, matz has rejected the 1st case, and preferred explicit comparison with 0.
@nobu you mean basically like this?
```
if (success = compile_c_to_o(c_file, o_file)) {
```
to
```
if ((success = compile_c_to_o(c_file,...
jaruga (Jun Aruga)
12:55 AM Misc #15136: Fix -Wparentheses warnings
Those 2 cases are actually different.
IIRC, matz has rejected the 1st case, and preferred explicit comparison with 0.
nobu (Nobuyoshi Nakada)
07:36 AM Revision 32cff956 (git): * compile.c (compile_case): emit opt_case_dispatch only on optimized mode
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64792 b2dd03c8-39d4-4d8f-98ff-823fe69b080e mame (Yusuke Endoh)
05:32 AM Bug #15130: Nested Timeouts hang on cygwin
> https://bugs.ruby-lang.org/issues/15130#change-74114

I think I know what's going on (but need to do offline stuff).
Should have a patch for you to test in a few hours.
normalperson (Eric Wong)
03:32 AM Bug #15130: Nested Timeouts hang on cygwin
This issue doesn't exist before #15072 started at r64485 and made it impossible to check whether open-uri works or not. I'm assigning this to Eric (normalperson) because it may well be timeout-related. Sorry if that turns out not to be t... duerst (Martin Dürst)
05:31 AM Revision d6d444d6 (git): fix typo [ci skip]
This error does not happen right now so this typo is
not serious, unless you locally edit insns.def.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64791 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
shyouhei (Shyouhei Urabe)
03:32 AM Bug #15072 (Open): thread.c:4356:5: error: implicit declaration of function ‘ubf_list_atfork’
duerst (Martin Dürst) wrote:
> That fix worked, thanks! Committed with r64635, okay on travis, not sure about other CIs.
Sorry for reopening. It seemed to work, but it left #15130. So I'm reopening this.
The issue here started wit...
duerst (Martin Dürst)
03:18 AM Feature #14097 (Closed): Add union and difference to Array
Applied in changeset trunk|r64787.
----------
Add union method to Array
I introduce a `union` method equivalent to the `|` operator, but which
accept more than array as argument. This improved readability, and it
is also coherent with ...
nobu (Nobuyoshi Nakada)
03:18 AM Revision ce079f16 (git): Introduce rb_ary_union_hash method in Array
Avoid repeating code and improve readability in `rb_ary_or` and
`rb_ary_union_multi`. Similaty as done with `rb_ary_union`.
[Fix GH-1747] [Feature #14097]
From: Ana María Martínez Gómez <ammartinez@suse.de>
git-svn-id: svn+ssh://ci.ru...
nobu (Nobuyoshi Nakada)
03:18 AM Revision 4c082239 (git): Link Array#union from | method
`Array#uniq` is not really related with `Array#|`, so I replaced it by
`Array#union`.
[Fix GH-1747] [Feature #14097]
From: Ana María Martínez Gómez <ammartinez@suse.de>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64789 b2dd03c8-...
nobu (Nobuyoshi Nakada)
03:18 AM Revision d0f9184f (git): Introduce rb_ary_union method in Array
Avoid repeating code and improve readability in `rb_ary_or` and
`rb_ary_union_multi`.
[Fix GH-1747] [Feature #14097]
From: Ana María Martínez Gómez <ammartinez@suse.de>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64788 b2dd03c8-...
nobu (Nobuyoshi Nakada)
03:18 AM Revision 744e816f (git): Add union method to Array
I introduce a `union` method equivalent to the `|` operator, but which
accept more than array as argument. This improved readability, and it
is also coherent with the `+` operator, which has a similar `concat`
method. The method doesn't ...
nobu (Nobuyoshi Nakada)
01:43 AM Bug #15087 (Closed): Segmentation fault with splat and block
Applied in changeset trunk|r64786.
----------
parse.y: fix block passing with empty kwargs
* parse.y (arg_blk_pass): preceeding arguments node may be NULL when
an empty keyword argument hash splat is optimized away.
[ruby-core:8889...
nobu (Nobuyoshi Nakada)
01:23 AM Bug #15087: Segmentation fault with splat and block
mame (Yusuke Endoh) wrote:
> Good catch. My patch for #15052 will fix this issue.
We have never agreed with how to fix #15052 yet. Nobu is working on this issue without behavior change.
mame (Yusuke Endoh)
01:43 AM Revision d325d741 (git): parse.y: fix block passing with empty kwargs
* parse.y (arg_blk_pass): preceeding arguments node may be NULL when
an empty keyword argument hash splat is optimized away.
[ruby-core:88890] [Bug #15087]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64786 b2dd03c8-39d4-4d8f-9...
nobu (Nobuyoshi Nakada)

09/19/2018

10:11 PM Feature #14097: Add union and difference to Array
@matz
> The final proposal seems reasonable. Accepted.
Great to read that! 🎉
I have just rebased in [the PR](https://github.com/ruby/ruby/pull/1747), looking forward to see the `Array#union` method in Ruby!
@shevegen
> ......
ana06 (Ana Maria Martinez Gomez)
05:30 PM Bug #15142 (Third Party's Issue): Bug in the Ruby interpreter or extension libraries
~|2]> brew cleanup
Removing: /usr/local/Cellar/sqlite/3.24.0... (11 files, 3.5MB)
/usr/local/Homebrew/Library/Homebrew/cache_store.rb:35: [BUG] Segmentation fault at 0x000000011d7ffffe
ruby 2.3.7p456 (2018-03-28 revision 63024) [unive...
pcsien61 (PC Sien)
05:12 PM Revision b06bcff4 (git): * 2018-09-20
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64785 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
05:12 PM Revision d93dcd28 (git): net/http: Improve net/http header error message.
Patch by Matt Larraz. [Fix GH-1849].
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64784 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Marc-Andre Lafortune
04:32 PM Misc #15136: Fix -Wparentheses warnings
> You say "I fixed the warnings". So why is this issue still open.
Sorry it's mistake. Correctly I fixed the warnings on my git repository, and sent pull-request. And not merged in the main repository's trunk.
The patch is here.
...
jaruga (Jun Aruga)
04:42 AM Misc #15136: Fix -Wparentheses warnings
jaruga (Jun Aruga) wrote:
> Before the modification, there were 18 warnings for `-Wparentheses`.
My crude guess is that all of them would be for cases such as "assignment in a context where a truth value is expected" (first paragraph...
duerst (Martin Dürst)
12:39 PM Revision 4baf0757 (git): ruby_2_2 branch has ended
https://www.ruby-lang.org/en/news/2018/06/20/support-of-ruby-2-2-has-ended/
[ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64783 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
znz (Kazuhiro NISHIYAMA)
10:26 AM Bug #15140 (Feedback): Bug in Interpreter or Extension Libraries
Could you try the latest version of 2.3?
Note that 2.3 series is security maintenance status already, and ordinary bug fixes will not be released anymore.
nobu (Nobuyoshi Nakada)
07:33 AM Bug #15140 (Closed): Bug in Interpreter or Extension Libraries
```
13:03:32 ASP.1 | started with pid 8751
13:03:33 ASP.1 | /home/psqa/.rvm/gems/ruby-2.3.3/gems/bundler-1.16.2/lib/bundler/remote_specification.rb:34: [BUG] Segmentation fault at 0x00000000000000
13:03:33 ASP.1 | ruby 2.3.3p222 (2...
meesala.gagan (Mesala Gagan)
08:23 AM Revision 41cf596d (git): process.c (waitpid_cleanup): unconditionally remove from waiters
This is the safer option, as there seems to be cases where checking
waitpid_state.ret is insufficient in ensure. I'm not 100% sure
why this is, but this change was required for my work-in-progress
Thread::Light patch series, too...
git...
Eric Wong
02:10 AM Revision f0f13cff (git): * hash.c (rb_hash_update): fix indent
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64781 b2dd03c8-39d4-4d8f-98ff-823fe69b080e mame (Yusuke Endoh)
02:10 AM Revision f7f216ed (git): [DOC] Add changes to Hash#merge in NEWS [#15111]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64780 b2dd03c8-39d4-4d8f-98ff-823fe69b080e Marc-Andre Lafortune
02:07 AM Revision bfbf9bd6 (git): * hash.c (rb_hash_update): remove a meticulous explanation
As per Marc-Andre's comment. [Refs GH-1951]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64779 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
mame (Yusuke Endoh)
01:59 AM Feature #15111 (Closed): Make the number of arguments of `Hash#merge` variable
Applied in changeset trunk|r64777.
----------
* hash.c (rb_hash_merge): Accepts zero or more hashes as arguments
Hash#merge, merge!, and update could merge exactly two hashes.
Now, they accepts zero or more hashes as arguments so that ...
mame (Yusuke Endoh)
01:45 AM Feature #15111 (Assigned): Make the number of arguments of `Hash#merge` variable
As I recall, Matz has accepted this ticket at the day of developers' meeting. I'll commit it soon. mame (Yusuke Endoh)
01:59 AM Revision d6a06a76 (git): * 2018-09-19
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64778 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
01:59 AM Revision 085f5ef9 (git): * hash.c (rb_hash_merge): Accepts zero or more hashes as arguments
Hash#merge, merge!, and update could merge exactly two hashes.
Now, they accepts zero or more hashes as arguments so that it can merge
hashes more than two.
This patch was created by Koki Ryu <liukoki@gmail.com> at Ruby Hack
Challenge #...
mame (Yusuke Endoh)
01:59 AM Bug #15078: Hash splat of empty hash should not create a positional argument.
akr (Akira Tanaka) wrote:
> We can create `{}` with a special instance variable to distinguish them.
I'm impressed by your creativity :-)
So, would we have the following?
```
def foo(**opt)
opt.instance_variable_get(:@no_ke...
marcandre (Marc-Andre Lafortune)

09/18/2018

11:00 PM Bug #15139 (Third Party's Issue): Bug in Interpreter or Extension Libraries
This is reference to upgrading Ruby from Homebrew on a 2017 MacBook Pro running OS X (MacOS) High Sierra 10.13.6 (17G65)
Ruby -v:
ruby 2.3.7p456 (2018-03-28 revision 63024) [universal.x86_64-darwin17]
I attempted a "brew upgrade" ...
gomberg@synair.com (Jeffrey Gomberg)
05:12 PM Bug #15138 (Closed): non-symbol keyword in double splat, such as **{2 => 3}, raises TypeError or not
I found that non-symbol keyword in double splat, such as `**{2 => 3}`,
raises TypeError in a situation and doesn't raise in another situation:
```
% ./ruby -ve '
def m(*a) p a end
m(k: 1, **{2 => 3}) # [{:k=>1, 2=>3}]
m(**{4 => 5...
akr (Akira Tanaka)
04:24 PM Misc #15129: DevelopersMeeting20181010Japan
[[Feature #15123]](https://bugs.ruby-lang.org/issues/15123) Enumerable#compact proposal (greggzst)
It simplifies working with large and small collections so one doesn't have to remember that can't use `#compact` when enumerator is retur...
greggzst (Grzegorz Jakubiak)
03:46 PM Bug #15078: Hash splat of empty hash should not create a positional argument.
My fourth idea: FL_USERn flag in `{}'. akr (Akira Tanaka)
02:34 PM Bug #15078: Hash splat of empty hash should not create a positional argument.
akr (Akira Tanaka) wrote:
> If it is not acceptable, I have second idea:
My third idea is to use an instance variable to distinguish
the two kind of `{}`.
We can create `{}` with a special instance variable to distinguish them....
akr (Akira Tanaka)
01:07 PM Bug #15078: Hash splat of empty hash should not create a positional argument.
mame (Yusuke Endoh) wrote:
> akr (Akira Tanaka) wrote:
> ...
Yes. I hope that the incompatibility is acceptable.
If it is not acceptable, I have second idea:
We can use a special frozen empty Hash object instead of nil.
```
NO...
akr (Akira Tanaka)
02:16 AM Bug #15078: Hash splat of empty hash should not create a positional argument.
akr (Akira Tanaka) wrote:
> How about def `m(**kw) end` binds kw to nil if the last Hash argument is not taken as keyword arguments and
> ...
Very clever :-)
As Mame-san points out, it would be a source of incompatibility. I would r...
marcandre (Marc-Andre Lafortune)
12:08 AM Bug #15078: Hash splat of empty hash should not create a positional argument.
akr (Akira Tanaka) wrote:
> How about def `m(**kw) end` binds kw to nil if the last Hash argument is not taken as keyword arguments and
> ...
I agree that it is one of the reasonable design choices, but does it break the following code...
mame (Yusuke Endoh)
02:56 PM Bug #15137 (Third Party's Issue): Can't run brew cleanup
I'm using Homebrew for Mac and I recently ran an update, followed by an upgrade. As usual, I ran cleanup afterward using "brew cleanup". Unfortunately the cleanup crashed. I cannot complete a brew cleanup and I'm getting the following e... budrecki (Tony Budrecki)
02:49 PM Misc #15136: Fix -Wparentheses warnings
Before the modification, there were 18 warnings for `-Wparentheses`.
```
$ make >& make.log
$ grep -r Wparentheses make.log | wc -l
18
```
jaruga (Jun Aruga)
02:43 PM Misc #15136 (Open): Fix -Wparentheses warnings
Currently the `-Wno-parentheses` was set.
I assumed if we could fix the warning, we could remove the `-Wno-parentheses`.
I fixed the warnings, because the warning is used as a default on Fedora Project build environment.
I sent pull...
jaruga (Jun Aruga)
01:52 PM Revision a4675d9d (git): * expand tabs.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64776 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
01:52 PM Revision e7db9df9 (git): vm_insnhelper.c: always use bool-ish value
for CC_SET_FASTPATH condition. Just a cosmetic change to unify the
styling with other lines.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64775 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
k0kubun (Takashi Kokubun)
12:55 PM Revision c49559f1 (git): Skip EHOSTUNREACH by host issues
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64774 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
12:49 PM Bug #15135 (Closed): Refining #initialize method not working
From the reference (https://docs.ruby-lang.org/en/2.5.0/syntax/refinements_rdoc.html):
>Refinements are lexical in scope.
> ...
So `initialize` which is called outside of the scope will not be overridden.
Matz.
matz (Yukihiro Matsumoto)
09:37 AM Bug #15135 (Closed): Refining #initialize method not working
See the following example:
```
class C
def initialize(arg)
puts arg
end
end
module M
refine C do
def initialize(arg1, arg2)
puts arg1, arg2
end
end
end
using M
C.new("foo") # works
C.new("f...
cbruckmayer (Christian Bruckmayer)
12:48 PM Revision 36850b78 (git): * expand tabs.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64773 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
12:48 PM Revision 62327bb6 (git): vm_insnhelper.h: rename CI_SET_FASTPATH to CC_SET_FASTPATH
because it's actually setting fastpath to cc instead of ci since r51903.
vm_insnhelper.c: ditto
mjit_compile.c: ditto
tool/ruby_vm/views/_mjit_compile_send.erb: ditto
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64772 b2dd03c8-39d...
k0kubun (Takashi Kokubun)
09:58 AM Feature #5400: Remove flip-flops in 2.0
Just a quick opinion, deprecation is part of the migration part, better warn in a release in between than break functionality immediately.
We also warn for continuation FWIW.
I support removing flip-flops, it looks like a legacy stra...
Eregon (Benoit Daloze)
09:22 AM Feature #5400: Remove flip-flops in 2.0
mame@ruby-lang.org wrote:
> There were some programs that used flip-flops in build
> scripts. I rewrote them to a code that does not use
> flip-flops. The work was harder than I expected.
>
> Honestly I'm unsure if deprecation of...
normalperson (Eric Wong)
09:16 AM Bug #15116: Fixing issues detected by an Analysis tool.
Thank you, fixed it now. nobu (Nobuyoshi Nakada)
08:34 AM Bug #15116: Fixing issues detected by an Analysis tool.
Thank you for clarifying it!
By the way, I saw your commit for the fix.
https://github.com/ruby/ruby/commit/eddd630
```
- close(slave);
+ if (slave < 0 && slave > 2) (void)!close(slave);
```
It seems that the `close`...
jaruga (Jun Aruga)
12:16 AM Bug #15116: Fixing issues detected by an Analysis tool.
POSIX states successfully opened file descriptors should be **non-negative**.
http://pubs.opengroup.org/onlinepubs/9699919799/functions/open.html#tag_16_357_04
> #### RETURN VALUE
> ...
pty.c should be more defensive too, thank you ...
nobu (Nobuyoshi Nakada)
09:15 AM Revision 742df62e (git): pty.c: typo
* ext/pty/pty.c (chfunc): fix a typo of an operator. pointed out by
jaruga (Jun Aruga) at [ruby-core:89058]. [Bug #15116]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64771 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
08:49 AM Bug #14908 (Closed): Enumerator::Lazy creates unnecessary Array objects.
Applied in changeset trunk|r64770.
----------
Lazy Enumerator reduce intermediate array creation
[ruby-core:87907] [Bug #14908] [Fix GH-1912]
From: Anmol Chopra <chopraanmol1@gmail.com>
nobu (Nobuyoshi Nakada)
06:43 AM Bug #14908: Enumerator::Lazy creates unnecessary Array objects.
No objection. I guess @nobu is trying to fix it. shyouhei (Shyouhei Urabe)
05:48 AM Bug #14908: Enumerator::Lazy creates unnecessary Array objects.
All the responses for the proposed patch are positive till date. @shyouhei can we go ahead with this now? chopraanmol1 (Anmol Chopra)
08:49 AM Revision aefdd4e2 (git): Lazy Enumerator reduce intermediate array creation
[ruby-core:87907] [Bug #14908] [Fix GH-1912]
From: Anmol Chopra <chopraanmol1@gmail.com>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64770 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
08:37 AM Revision ec6c0757 (git): Merge upstream revision of rubygems/rubygems.
This commits includes tiny bugfix and new features listed here:
* Add --re-sign flag to cert command by bronzdoc: https://github.com/rubygems/rubygems/pull/2391
* Download gems with threads. by indirect: https://github.com/rubyge...
hsbt (Hiroshi SHIBATA)
08:30 AM Revision 3367daf7 (git): Tests of Enumerator::Yielder#yield with multiple arguments
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64768 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
07:15 AM Bug #15121 (Rejected): Memory Leak on rb_id2name(SYM2ID(sym))
Yes, it is expected.
We separate all symbols into two categories:
* static symbols: used by method name and so on. They are not GC'ed managed.
* dynamic symbols: created by Ruby program like `str.to_sym`.
Static symbols are use...
ko1 (Koichi Sasada)
03:44 AM Feature #14183: "Real" keyword argument
Very interesting.
akr (Akira Tanaka) wrote:
> The flag will be true if method call uses k => v, k: v, "k": v or **h and
> ...
I agree that hash separation is not a good idea. I'm wondering if `(k = :a) => v` should be accepted. It i...
marcandre (Marc-Andre Lafortune)
12:00 AM Feature #14183: "Real" keyword argument
`keyword_given?` provides information about the caller side.
The information is not related to callee side.
There is no chance to call `keyword_given?` if ArgumentError is raised, though.
For simplicity, I assume keys for keyword ar...
akr (Akira Tanaka)
12:38 AM Feature #14927: Loading multiple files at once
Until we convince Matz, I pushed a gem `require_relative_dir` which hopefully can be helpful to others. marcandre (Marc-Andre Lafortune)
12:22 AM Revision 32fd8649 (git): * 2018-09-18
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64767 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
12:22 AM Revision eddd6300 (git): pty.c: more difensive
* ext/pty/pty.c (chfunc): should not close the slave fd if it is 0..2.
[ruby-core:89043] [Bug #15116]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64766 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)

09/17/2018

11:43 PM Bug #15116: Fixing issues detected by an Analysis tool.
Negative fd means `open(2)` failed. nobu (Nobuyoshi Nakada)
03:31 PM Bug #15116: Fixing issues detected by an Analysis tool.
Thank you for checking my code!
> > Fix leaked handle variable "n" in process.c.
> ...
About above thing,
I compared process.c#rb_daemon with pty.c#chfunc .
Similar implementation, but a little different.
https://github.com/ru...
jaruga (Jun Aruga)
11:35 PM Bug #15118 (Closed): Method [] & []= does not respect frozen_string_literal: true comment
Thank you, I missed the reference to this ticket in the commit log. nobu (Nobuyoshi Nakada)
09:56 AM Bug #15118: Method [] & []= does not respect frozen_string_literal: true comment
@nobu : should this ticket be closed or not yet?
it seems fixed in 64745
Hanmac (Hans Mackowiak)
07:01 PM Bug #15082: Memory leak in net/http/response and net/http/header
I kept to investigate the memory leak issue. It seems it comes when OpenSSL::SSL::VERIFY_PEER is enabled and a ca_file is specified :
~~~ ruby
require "net/http"
require "openssl"
def repeat_https_get
uri = URI("https://exampl...
alexis (Alexis Bernard)
02:56 PM Feature #14183: "Real" keyword argument
akr (Akira Tanaka) wrote:
> I have an idea to separate positional arguments and keyword arguments without incompatibility.
I like this idea of allowing per-method handling of arguments. Just to confirm my understanding of the propos...
jeremyevans0 (Jeremy Evans)
05:22 AM Feature #14183: "Real" keyword argument
I have an idea to separate positional arguments and keyword arguments without incompatibility.
Basic idea is introducing an flag, keyword_given,
which means the last argument is a Hash object which represent keyword argument.
(The n...
akr (Akira Tanaka)
11:21 AM Bug #15078: Hash splat of empty hash should not create a positional argument.
akr (Akira Tanaka) wrote:
> In this behavior, following two should be same behavior (in Ruby 2.X), I think.
> ...
Oops. ```def f(*a, *kw) g(*a, *kw) end``` was wrong.
I wanted to write ```def f(*a, **kw) g(*a, **kw) end```
Also, ...
akr (Akira Tanaka)
05:53 AM Bug #15078: Hash splat of empty hash should not create a positional argument.
mame (Yusuke Endoh) wrote:
> ```
> ...
How about def `m(**kw) end` binds kw to nil if the last Hash argument is not taken as keyword arguments and
`m(**{})` add {} and `m(**nil)` don't add anything to arguments.
{}/nil distinguis...
akr (Akira Tanaka)
04:31 AM Bug #15130 (Closed): Nested Timeouts hang on cygwin
After using `make; make runnable`, the following one-liner hangs:
```
./ruby -ropen-uri -e 'open "http://web.mit.edu/index.html"'
```
This happens on any http URI, but not for local files. The above URI is just an example. I wou...
duerst (Martin Dürst)
01:31 AM Revision 7c5d475d (git): * 2018-09-17
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64765 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
01:31 AM Revision 433c2714 (git): common.mk: ruby tool/update-deps --fix
tool/update-deps: tweak the comment to make sure it should be built in
the source directory, because building ruby outside source directory
failed on my trial.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64764 b2dd03c8-39d4-4d8f-9...
k0kubun (Takashi Kokubun)
 

Also available in: Atom