Activity
From 04/28/2019 to 05/04/2019
05/04/2019
-
04:54 PM Bug #15823 (Closed): ARGF.lineno behavior and documentation disagree
- The documentation for `ARGF.each` at http://ruby-doc.org/core-2.6.3/ARGF.html#method-i-each
describes `ARGF.lineno` as if it behaved like `ARGF.file.lineno`, when it behaves for me like `$.`
Here's the sample code from the documentat... -
03:29 PM Revision ff21e75d (git): parse.y: duplicated when clause warning
- * parse.y (case_args): moved "duplicated when clause" warning from
compile phase, so that `ruby -wc` shows them. - 02:32 PM Revision 848edb03 (git): ignore test_RangeError
-
01:50 PM Feature #15822 (Closed): Add Hash#except
- According to `Hash#slice`, I would like to add `Hash#except`. Same for `ENV.except`.
-
01:31 PM Revision a380f4c2 (git): Fix typos, grammar, and style
-
01:02 PM Revision 8bf3040e (git): Fix grammar
-
01:00 PM Revision b9e52db2 (git): Add a pathologic check
-
10:29 AM Bug #15711 (Closed): Remove use of _id2ref from DRb - Applied in changeset commit:git|8980b53a48b1f55e09c5223008225e6bfa765405.
----------
add DRb::WeakIdConv (Bug #15711) - 10:29 AM Revision 7d30cd47 (git): * remove trailing spaces.
- 10:28 AM Revision 8980b53a (git): add DRb::WeakIdConv (Bug #15711)
-
05:42 AM Bug #15821 (Closed): ruby_process_options() may cause "WB miss (O->Y)"
- ## Problem
Ruby interpreter may cause error "WB miss (O->Y)" on some conditions that are `RGENGC_CHECK_MODE=5` and `RUBY_DEBUG=gc_stress`
## How to reproduce
1. build ruby with high RGENGC_CHECK_MODE
* `make ruby optflags="-... -
12:49 AM Bug #15775 (Closed): Update broken URL in Float documentation
05/03/2019
-
09:23 PM Revision b7262301 (git): Update broken URL in Float documentation.
- [Misc #15775][ruby-core:92332]
-
06:41 PM Bug #15775: Update broken URL in Float documentation
- @hsbt: Just wanted to ping you about this small update of the Float documentation (maybe you can reassign it to someone who could review it?). Thanks!
-
04:36 PM Bug #15787: LoadError by EPERM on read-only volume
- Ok, i consulted with PulkoMandy, one of the main Haiku developer, he meant it is not possible to unset "O_NONBLOCK or O_NDELAY because we don't allow it" on packaged file-system. This is why this check fails.
We make it sure the file op... - 03:00 PM Revision a3cbce78 (git): * 2019-05-04
- 02:59 PM Revision 04fd98d5 (git): * expand tabs.
-
02:59 PM Revision 77440e94 (git): Improve performance of case-conversion methods
-
02:12 PM Revision 1f349ea2 (git): Fix typo
-
11:31 AM Bug #15820 (Closed): Backport 5e23b1138f1 (Fix potential memory leak)
- The fix for the potential memory leak (https://github.com/ruby/ruby/commit/5e23b1138f16af0defb184d7deeffadfd2ce3c04) should be backported into stable branches.
-
09:04 AM Bug #15819: cannot read document of File::NULL with "ri File::NULL"
- > IHMO, it's too difficult to guess proper command.
Agree - File::NULL works in e. g. irb too and should work for ri. I found rdoc/ri
a bit cumbersome to use API-wise; in one project, that displays rdoc documentation
for methods (a ... -
04:58 AM Bug #15819: cannot read document of File::NULL with "ri File::NULL"
- When I type `ri File::NULL`, got
> Nothing known about File::NULL
> ...
but
* `ruby -e 'p File::NULL'` prints `"/dev/null"` succesfully
* Documents are already written in #7365
* I could read it with `ri File::File::Constants`
... -
04:50 AM Bug #15819 (Closed): cannot read document of File::NULL with "ri File::NULL"
-
06:33 AM Revision 5776ae34 (git): UTF-8 is one of byte based encodings
05/02/2019
- 09:26 PM Revision 58cd4b7b (git): * 2019-05-03
- 09:24 PM Revision 7d02bab0 (git): Nil cannot and should not convert to a string
- 09:16 PM Revision 6610b77e (git): merge revision(s) 66324: [Backport #15385]
- Modify insn list only when compiling
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67708 b2dd03c8-39d4-4d8f-98ff-823fe69b080e -
05:52 PM Feature #15818 (Rejected): Please hide ruby-doc.org pages for EOL releases from the Google index
- As far as I know, ruby-doc.org is a third-party project. The footer of the site says:
> Ruby-doc.org is hosted and maintained by James Britt and the Neurogami secret laboratory.
> ...
So, please contact on that email address.
(I'... -
05:32 PM Feature #15818: Please hide ruby-doc.org pages for EOL releases from the Google index
- I don't have a particular pro/con opinion on the suggestion itself, but I do agree with the problem
that we often end up finding old(er) documentation by default - most certainly when doing a search
through Google but perhaps also by u... -
05:03 PM Feature #15818 (Rejected): Please hide ruby-doc.org pages for EOL releases from the Google index
- It's a very common experience that if I google a Ruby method or class, the top Google link to me points to the docs for Ruby 2.2 or 2.1 or even 1.9 or 1.8. As a recent example, googling [ruby unicode_normalize] finds me https://ruby-doc....
-
04:56 PM Feature #1089: Stable sorting for sort and sort_by
- One use case I have for a stable sort is a large CSV file which is tracked in a git repository. I have a script which loads the file, adds rows, and then sorts all rows by a particular column before writing them back to the file. I nee...
-
02:41 PM Feature #11076: Enumerable method count_by
- > "map + select" is much more frequent, but it is not introduced yet
I think it would also be nice if `filter_map` was added. However, a specific justification for adding `tally_by` is to avoid an extra array allocation. `filter_map... - 01:44 PM Revision 5c87bb3b (git): * expand tabs.
-
01:44 PM Revision 5e23b113 (git): Fix potential memory leak
-
10:43 AM Bug #15794: Can not start Puma with Rails after bundle install
- I resolved my issue, it due to some versions of my gems. I updated my gem to the latest version and it works now.
Thank you -
09:11 AM Feature #15817 (Open): Warnings for undef_method and remove_method on initialize()
- Title: Warnings for undef_method and remove_method on initialize()
Right now ruby warns you if you remove or undefine initialize, at the least if you
run in verbose mode e. g. the -w flag.
Example for such a warning:
gtk_co... - 05:47 AM Revision d6efb386 (git): * 2019-05-02
-
05:44 AM Revision a1ae478a (git): Fix a typo
05/01/2019
-
11:03 PM Feature #14736: Thread selector for flexible cooperative fiber based concurrency
- > Also, should we try to handle IOs which are not explicitly set as #nonblock=true?
I guess in my proof of concept I wanted to do the bare minimum to show if it would work. But using `io/nonblock` is a bit of an ugly hack, so I person... -
10:41 PM Feature #14736: Thread selector for flexible cooperative fiber based concurrency
- > how to handle disk IO such as File.read
While many platforms don't support non-blocking disk IO, `liburing` for linux and `IOCP` on Windows might present some opportunities for increased concurrency. Alternatively, some implementat... -
03:15 PM Feature #14736: Thread selector for flexible cooperative fiber based concurrency
- In case it was not clear, I'm in favor of this change for Ruby 3.
I think it provides the essential primitives to build something powerful and flexible for efficient asynchronous IO in Ruby. -
03:11 PM Feature #14736: Thread selector for flexible cooperative fiber based concurrency
- We discussed this a bit at the Ruby developer meeting before RubyKaigi and @matz asked me to share my opinion on the bug tracker.
I also attended @ioquatix's talk at RubyKaigi and it was quite convincing.
Basically, the main outcom... -
10:36 PM Misc #15782: DevelopersMeeting20190522Japan
- * [Feature #14736] Thread selector for flexible cooperative fiber based concurrency
* Is it something we want to move forward with?
* Extend hooks for `wait_one_pid` and `Kernel::sleep`. Are there other areas to hook into?
* Add so... -
10:07 AM Misc #15782: DevelopersMeeting20190522Japan
- * [Misc #15800] [PATCH] Reduce `ONIG_NREGION` size from 10 to 4
* Power of 2 and testing revealed most pattern matches are less than or equal to 4 results
* `MatchData` instances over allocate memory for the most common cases
* [Mis... -
10:27 PM Bug #15816 (Closed): String#casecmp compares uppercase characters instead of lowercase
- The current implementation of `String#casecmp` converts characters to uppercase before comparing them. However, all references I've found for `strcasecmp` (the C function on which `String#casecmp` is based) indicate characters should be...
-
05:47 PM Feature #15815: Add option to raise NoMethodError for OpenStruct
- > Note that you might be able to write `users.map{@[:id]}` in the next version and
> ...
I think that the idiom, or "mental mode", e. g. how users use ruby, is a bit different
between the two examples. At the least to me, "OpenStruct" ... -
05:09 PM Feature #15815: Add option to raise NoMethodError for OpenStruct
- It's hard to decide on features of `OpenStruct` as it's somewhat an antipattern.
Note that you might be able to write `users.map{@[:id]}` in the next version and avoid using an `OpenStruct` altogether.
That being said, I am wonderi... -
01:52 PM Feature #15815 (Assigned): Add option to raise NoMethodError for OpenStruct
- GitHub PR: https://github.com/ruby/ruby/pull/2164
Currently, `OpenStruct#method_missing` returns `nil` even if the key isn't registered.
```ruby
require 'ostruct'
os = OpenStruct.new({a: 1})
os.a #=> 1
os.b #=> nil
```
I'd ... -
04:22 PM Bug #15791: Clarify reason for RbConfig's ruby_version not reflecting "teeny" value
- I assume it was decided a long time ago. 1.9.3 has a value of 1.9.1.
Maybe a decision was made later that ABI versions would only change on minor releases? -
01:54 PM Bug #15810: Windows spec failure - Process.ppid returns the process id of the parent of this process - ??
- Would it be possible to use execve() in RUNRUBY, such that RUNRUBY and the actual ruby process have the same PID, or is that not available on Windows?
-
11:55 AM Revision 71952440 (git): Silence a (probable) debug print
-
11:47 AM Revision 474af9ee (git): No last commit when up-to-date
- Get the last commit title from the upstream to the head, so that
no `last_commit` line will be shown when the branch is up to date
with the upstream. -
11:27 AM Revision 2f0f9115 (git): Ignore ChangeLog
- 08:38 AM Revision dcb6a6ae (git): Windows simply causes an error to open invalid path
-
08:21 AM Feature #15814 (Closed): Capturing variable in case-when branches
-
08:03 AM Feature #15814: Capturing variable in case-when branches
- #14912 is more thought-out and seems to have made good progress, my regret is I didn't come upon it when trying to search for duplicate issues. #14709 seems to have a collection of case studies and really interesting discussions, but "if...
-
04:34 AM Feature #15814: Capturing variable in case-when branches
- That is the exactly same feature which I proposed yeas ago and was rejected.
-
04:31 AM Feature #15814: Capturing variable in case-when branches
- What is the relationship with #14912 that already committed?
-
04:25 AM Feature #15814: Capturing variable in case-when branches
- I messed up brackets.
-
04:24 AM Feature #15814 (Closed): Capturing variable in case-when branches
- In ruby, when a case-when statement is written, the when branches accepts expressions which will be evaluated to objects, then === is called to check if any of them returns true:
```ruby
case 'a'
when 'abc'
# not matched
when Re... -
01:53 AM Feature #15799: pipeline operator
- Eregon (Benoit Daloze) wrote:
> To be fair, I don't particularly like Haskell code and find it very cryptic, which this is getting closer to.
Haskell code can be very clear (or very cryptic). In my personal experience, I found the ...
04/30/2019
-
09:35 PM Feature #15323: [PATCH] Proposal: Add Enumerable#filter_map
- alfonsojimenez (Alfonso Jiménez) wrote:
> I've updated the patch file increasing the ruby version in *spec/ruby/core/enumerable/filter_map_spec.rb*
> ...
Does the syntax allow for this kind of code?
~~~ruby
(1..10).filter_map(&:eve... -
09:20 PM Bug #15745: There is no symmetry in the beginless range and the endless range using `Range#inspect`
- I didn't realize, but Range#to_s and Range#inspect differ by calling #to_s and #inspect on both ends:
```
puts ('a'..'z').to_s
# => a..z
puts ('a'..'z').inspect
# => "a".."z"
```
Following that, for `("a"..)` we'd get `a..` and ... -
05:22 PM Bug #15745: There is no symmetry in the beginless range and the endless range using `Range#inspect`
- > I'd like to avoid "don't care". Even if we don't care, we need to choose one of them.
Yes, but from my perspective, the whole choice (being it a further discussion, simple voting, Matz's decision) is only about "how the `nil..nil` i... -
05:06 PM Bug #15745: There is no symmetry in the beginless range and the endless range using `Range#inspect`
- Oops, I'm sorry, parentheses are not rendered in the result of `inspect`. Let me rephrase and include (3):
(0) Keep the current behavior: `p (1..) #=> 1..`, `p (..1) #=> nil..1`, and `p (nil..nil) #=> nil..`.
(1) Make all cases expl... -
04:41 PM Bug #15745: There is no symmetry in the beginless range and the endless range using `Range#inspect`
- My reasoning is semi-open ranges are valuable feature, and by `inspect` we should suggest to users their "naturalness", not "it is just a quick hack, look".
Explicit rendering of `nil` is *underlining* some kind of "hackiness" ("it is ... -
04:02 PM Bug #15745: There is no symmetry in the beginless range and the endless range using `Range#inspect`
- I think we digress. I had no intention to discuss a beginless range itself, but maybe it started digressing. My apologies. Let's focus on the original topic in this ticket.
Do you think which is the best?
(0) Keep the current be... -
04:38 PM Feature #14784: Comparable#clamp with a range
- I agree this would be a useful feature. I have a library that implements this as `Comparable#at_least(min)` and `Comparable#at_most(max)`, but `clamp(min..)` and `clamp(..max)` feel more idiomatic (although they do require an extra obje...
-
04:07 PM Revision fc3e80cf (git): guard include with has_feature
- clang's sanitizer/msan_interface.h has fallback macros.
It causes redefinition of __msan_unpoison(). -
03:45 PM Revision 3de03544 (git): Add Reline.delete_text that raises NotImplementedError
-
03:10 PM Feature #15813: Proposal: Add exception support in `Range#first`
- Thanks!!!!!!!
-
03:06 PM Feature #15813 (Closed): Proposal: Add exception support in `Range#first`
-
03:06 PM Feature #15813: Proposal: Add exception support in `Range#first`
- Merged at 4e88e8692844a2a317bc19481f0f2601b6f00955. Thank you.
-
02:52 PM Feature #15813 (Closed): Proposal: Add exception support in `Range#first`
## Current status
Calling `Range#last` in endless range(`(1..)`) raises an exception.
```ruby
# OK
p (1..Float::INFINITY).end # => Infinity
p (1..).end # => nil
p (1..Float::INFINITY).last # => Infinity
...- 03:03 PM Revision c0682116 (git): * 2019-05-01
-
03:03 PM Revision 4e88e869 (git): Add exception support in `Range#first`.
- Closes: https://github.com/ruby/ruby/pull/2163
-
02:54 PM Misc #15782: DevelopersMeeting20190522Japan
- * [Feature #15813] Proposal: Add exception support in `Range#first`
* I want to hear the opinions of developers -
01:35 PM Revision 0eedec68 (git): Change Accept-Encoding from `*` to `identity`
- When `Accept-Encoding` is `*`,
http://www.unicode.org/Public/12.1.0/ucd/ returns gzipped content now.
So set `identity`. -
01:29 PM Feature #15811: Propsing new method for comparing equality of 2 (float) numbers relatively
- duerst (Martin Dürst) wrote:
> Ruby is an object-oriented language. So I think this should be something like:
> ...
If it is an instance method, the relative tolerance feels relative to the absolute value of the receiver, not the large... -
10:50 AM Feature #15811: Propsing new method for comparing equality of 2 (float) numbers relatively
- Related to https://bugs.ruby-lang.org/issues/10425
-
08:16 AM Feature #15811: Propsing new method for comparing equality of 2 (float) numbers relatively
- Ruby is an object-oriented language. So I think this should be something like:
```
a.close_to?(b, abs_tolerance: t)
```
or so, not a function with two main numbers. -
07:23 AM Feature #15811: Propsing new method for comparing equality of 2 (float) numbers relatively
- I think it should be under `Math` or `Float`, and a independent gem could be a good first step.
- 01:24 PM Revision dd942cd5 (git): Use redirect keyword arguments instead of ">"
-
01:23 PM Revision 50872f4a (git): Use array mode of `system` instead of `shellescape`
- `&.` is not available in ruby 2.0.
- 01:20 PM Revision 764fe09a (git): merge revision(s) 67270: [Backport #15670]
- dsym should be treated as string [ruby-core:91852] [Bug #15670]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67707 b2dd03c8-39d4-4d8f-98ff-823fe69b080e -
01:13 PM Revision df3de409 (git): String#[] with index to extract matched substring safely
- 01:04 PM Revision e31f9b0a (git): merge revision(s) 67467: [Backport #15756]
- range.c: force hash values fixable
* range.c (method_hash): force hash values fixable on LLP64
environment. [ruby-core:92191] [Bug #15756]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67706 b2dd03c8-... - 01:02 PM Revision bf4a14a2 (git): merge revision(s) 67468: [Backport #15757]
- range.c: force hash values fixable
* range.c (range_hash): force hash values fixable on LLP64
environment. [ruby-core:92194] [Bug #15757]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67705 b2dd03c8-3... - 01:00 PM Revision 860e548a (git): merge revision(s) 67247: [Backport #15666]
- Guard out the test when it is run under root permission
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67704 b2dd03c8-39d4-4d8f-98ff-823fe69b080e - 12:55 PM Revision c8f77d37 (git): merge revision(s) 64057: [Backport #14952]
- Remove obsolete comment from Module#define_method documentation
Since 2.5, Module#define_method is public. (feature #14133)
Co-Authored-By: Miguel Landaeta <miguel@miguel.cc>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby... - 12:51 PM Revision 1dd94dfb (git): Must use IO::NULL instead of platform dependent filename
-
12:43 PM Bug #15812: Run specs from install folder?
- I wholeheartedly agree with that.
Supporting running specs from the non-installed `ruby` is significant work and hacks.
And testing what people use in production rather than a temporary build is of course much more meaningful.
But I... - 12:40 PM Revision bcdcee47 (git): merge revision(s) 66326,66649: [Backport #15385]
- Fix infinite loop by ensure
* compile.c (iseq_insert_nop_between_end_and_cont): insert nop so that the end of rescue and continuing points are not same, to get rid of infinite loop. [Bug #15385]
test_optimization.rb: increase timeout f... -
11:58 AM Feature #10394: An instance method on Enumerator that evaluates the block under with self being the block variable.
- Isn't it `instance_eval`?
- 10:45 AM Revision 830e40ee (git): Skip on Windows now when using reline because it causes hang of whole tests
-
10:34 AM Misc #15723: Reconsider numbered parameters
- If we are interested only in the entire single block parameter, then this https://bugs.ruby-lang.org/issues/10394 might be a possibility. We would then be able to refer to the parameter as `self` without modfying the syntax.
- 09:01 AM Revision 5a83a1d5 (git): **Must** use IO::NULL for null device
-
07:20 AM Revision c222f4d3 (git): `from` is not nil but `""` on shallow clone [ci skip]
-
06:32 AM Bug #15779: After NoMemoryError, ruby freezes and takes 100% CPU
- How about this?
```
diff --git a/vm.c b/vm.c
index 41064f07c3..be394b0dae 100644
--- a/vm.c
+++ b/vm.c
@@ -1895,7 +1895,7 @@ vm_exec(rb_execution_context_t *ec, int mjit_enable_p)
}
else {
result = ec->errinf... -
03:52 AM Bug #15779: After NoMemoryError, ruby freezes and takes 100% CPU
- I think it is from r58380.
before r58380, `rb_memerror` calls `rb_longjmp` via `rb_exc_raise` and clear raised_flag.
But now `rb_memerror` keeps raised_flag and just calls `EC_JUMP_TAG`.
`rb_threadptr_execute_interrupts` should ra... - 06:02 AM Revision 151b7d72 (git): Forgotten to remove
-
05:40 AM Revision 94b740b2 (git): Use Ripper for IRB
- The debug option of IRB is deleted because it's just for IRB's pure Ruby
parser. -
03:53 AM Revision 567cb1ae (git): Use Encoding::UTF_8 if RELINE_TEST_ENCODING doesn't exist
-
03:53 AM Revision 3be5907e (git): Move Win32API to Reline::Win32API
-
03:33 AM Revision 319eee0f (git): Use Encoding::UTF_8 if Encoding.default_external is Encoding::IBM437
-
02:44 AM Revision 17350c7e (git): Add Reline as a fallback library for Readline
- * lib/reine.rb, lib/reline/*: Reline is a readline stdlib compatible
library.
* lib/readline.rb: Readline uses a fallback to Reline when ext/readline
doesn't exist.
* tool/sync_default_gems.rb: add ruby/reline as a default gem.
* app...
04/29/2019
-
10:17 PM Bug #15791: Clarify reason for RbConfig's ruby_version not reflecting "teeny" value
- MSP-Greg (Greg L) wrote:
> I always consider `RbConfig::CONFIG['ruby_version']` as the ABI version, which is used in naming `--user-install` gem folders, etc.
> ...
Then why does it include `.0` at all? -
09:14 PM Bug #15812 (Closed): Run specs from install folder?
- 1. Currently, no testing is done on the install folder.
2. Configure/build & testing both take far longer than install
3. spec tests normally run directly in their repo (ruby/spec)
GitHub PR 2160 https://github.com/ruby/ruby/pull/21... -
07:26 PM Bug #15810: Windows spec failure - Process.ppid returns the process id of the parent of this process - ??
- @usa
I revised appveyor.yml to run specs from the install folder, and submitted a PR. I think running at least one test suite from it is a good idea, as the purpose is to create an install.
So, I reverted the commit that bypassed ... -
07:14 PM Bug #15810 (Closed): Windows spec failure - Process.ppid returns the process id of the parent of this process - ??
- in `test-spec` target of make, `RUBY_EXE` constant in mspec is `RUNRUBY`.
it means that the invoked ruby process is the grandchild of the invokee, not the child.
so, this spec is never passed on Windows via `make test-spec`. -
03:52 AM Bug #15810 (Closed): Windows spec failure - Process.ppid returns the process id of the parent of this process - ??
- Since being committed at 79671ec on 28-Apr, this spec has consistently failed:
```
Process.ppid returns the process id of the parent of this process FAILED
Expected "11424\n"
to equal "13044\n"
C:/projects/ruby/spec/ruby/core/p... - 07:09 PM Revision eb45ba61 (git): Skip the spec on Windows because RUBY_EXE is RUNRUBY and it calls ruby as grandchild
- 07:09 PM Revision 320f0aba (git): Revert previous commit; it was meaningless
- 06:33 PM Revision ae3a9862 (git): * expand tabs.
- 06:33 PM Revision 09022b6d (git): Use CreateToolhelp32Snapshot instead of NtQueryInformationProcess to get ppid on Windows
- Try to get rid of a spec error.
-
05:56 PM Feature #15236: add support for hash shorthand
- +1
I also vote for this option for both hashes and named params. After using Es6 and going back to Ruby, the ruby way felt clunky to me.
There are multiple reasons why this would be advantageous.
## Readability:
I like the ... -
04:22 PM Feature #15778: Expose an API to pry-open the stack frames in Ruby
- As a case study, we may look at Python. They have such an API for 20+ years and I don't think anyone explicitly complained it makes Python slow or dangerous to use. The API is `sys._getframe` (https://docs.python.org/3/library/sys.html#s...
- 03:28 PM Revision b7d9ec8c (git): * 2019-04-30
-
03:28 PM Revision 7a34d890 (git): Merge .time
-
02:55 PM Feature #15811: Propsing new method for comparing equality of 2 (float) numbers relatively
- The tests for this are incorrect and show why this does not work.
From the test gist
```ruby
context 'Numbers between 1 and 0' do
let (:absolute_tolerance) { 1.0E-14 }
it 'returns true for same positive numbers' do
expe... -
11:55 AM Feature #15811: Propsing new method for comparing equality of 2 (float) numbers relatively
- Not sure if the name `.close?` is a good name to indicate a relative comparison. Note that
I have no real pro or con opinion, just pointing out that the name may not be ideal. I
don't have a good alternative proposal either; perhaps so... -
11:35 AM Feature #15811: Propsing new method for comparing equality of 2 (float) numbers relatively
- hi.
Here are the guidelines.
https://github.com/ko1/rubyhackchallenge -
11:03 AM Feature #15811: Propsing new method for comparing equality of 2 (float) numbers relatively
- I don't know how to add the new method correctly. Please have a look at those gist and tell me what to do! Thank you :)
-
10:58 AM Feature #15811 (Open): Propsing new method for comparing equality of 2 (float) numbers relatively
- # Background
Equal comparison method between 2 float numbers returns unexpected results sometimes. Therefore, a relative comparison method is needed!
# Proposal
A relative equal comparison method has been written based on a Pyth... -
02:02 PM Revision 040b37f8 (git): Use 10 chars as RUBY_REVISION in snapshot too
-
12:52 PM Revision f95f07da (git): avoid passing NULL to memset
- `GC::Profiler.enable; GC::Profiler.clear` tries to clear
objspace->profile.records but it has never been allocated before.
Thus the MEMCPY took NULL argument before this changeset.
The objspace->profile.records is allocated appropriatel... -
12:52 PM Revision 34e1079a (git): glibc says memcpy cannot take NULL
- At least since 2004, glibc's <string.h> annotates memcpy as
__attribute__((__nonnull__)). This basedir is passed to it. When
LOAD_RELATIVE is not defined and MJIT_SEARCH_BUILD_DIR is not set,
this variable is never updated. Should ini... -
12:52 PM Revision e7b18ca6 (git): glibc says memcpy cannot take NULL
- At least since 2004, glibc's <string.h> annotates memcpy as
__attribute__((__nonnull__)). On the other hand the argv here,
which is passed from rb_funcallv, may be NULL. Practically this
should never be a serious problem but for maximu... -
12:52 PM Revision a116f04c (git): suppress some UBSAN sanitizers
- They are not "undefined". UBSAN reports them because it thinks
they are "often unintentional". We see the report rather annoying. -
12:52 PM Revision f4c68640 (git): this variable is not guaranteed aligned
- No problem for unaligned-ness because we never dereference.
-
12:52 PM Revision 7c0f513e (git): fix typo
-
10:34 AM Bug #15745: There is no symmetry in the beginless range and the endless range using `Range#inspect`
- > I think that an endless range will be much more commonly used than a beginless one because an endless range has many use cases but a beginless range has only one use case (DSL-like usage). Thus, I liked to make an endless one more usef...
-
12:05 AM Bug #15745: There is no symmetry in the beginless range and the endless range using `Range#inspect`
- Eregon (Benoit Daloze) wrote:
> I'm not sure what you mean by DSL-like usage, but I wouldn't be surprised if many people use it like `array[..-2]` (instead of `array[0..-2]`).
> ...
I meant "DSL-like", for example, `debtors = Accounts.... -
09:32 AM Revision 6a3165e1 (git): Fixed HERETERM_LENGTH_MAX on IL32LLP64
-
08:45 AM Revision c7f780c1 (git): Refactored rb_strterm_heredoc_t
-
04:47 AM Revision 1432471a (git): Disallow also CR in here-doc identifier
- * parse.y (heredoc_identifier): CR in here-document identifier
might or might not result in a syntax error, by the EOL code.
make a syntax error regardless of the EOL code. -
04:42 AM Revision 23375c8b (git): Make only `mesg` can be assigned with default `fname`
-
03:49 AM Revision 330b3761 (git): parse.y: fix here-doc identifier with newline
- * parse.y (heredoc_identifier): quoted here-document identifier
must end within the same line.
the only corner case that here-document identifier can contain a
newline is that the closing qoute is placed at the beginning of
the ... -
03:21 AM Revision 69cad44f (git): Reduce debug output
- because I found machine clock problem
see r67347
https://travis-ci.org/ruby/ruby/jobs/525784924
https://travis-ci.community/t/mtime-of-source-codes-are-sometimes-newer-than-build-time-clock-skew/3215 -
02:31 AM Revision 812a4381 (git): iseq.c: removed unnecessary zero-fills
-
01:37 AM Bug #15779: After NoMemoryError, ruby freezes and takes 100% CPU
- I test this reproduction code at ruby 2.5.5 (ruby 2.5.5p157 (2019-03-15 revision 67260) [x86_64-linux]). In this version, this issue is not reproduced (ruby is not frozen).
```
~/opt/ruby/2.5.5/bin/ruby a.rb
#<StringIO:0x0000560b3... -
01:36 AM Bug #15779: After NoMemoryError, ruby freezes and takes 100% CPU
- In this situation, I want ruby to finish GC quickly or to crash.
In my production code, this issue has been avoided by not creating huge objects and by using rescue and re-raise.
I attach strace log (`strace -ttt -o strace.txt ruby... -
01:11 AM Revision 6033423d (git): NEWS: Moved "Integer#[] with range" to "Core classes updates"
04/28/2019
-
09:29 PM Revision daa08740 (git): CLOCK_MONOTONIC_RAW_APPROX seems less precise than advertised on macOS
- * https://travis-ci.org/ruby/ruby/builds/525651487
-
09:20 PM Revision 79671ec5 (git): Update to ruby/spec@7de852d
-
09:20 PM Revision 99483308 (git): Update to ruby/mspec@c25d63d
-
09:17 PM Revision bbb93608 (git): Move the check for CentOS CLOCK_MONOTONIC_RAW next to others
- * Fixes "No behavior expectation was found in the example"
* https://rubyci.org/logs/rubyci.s3.amazonaws.com/centos6/ruby-trunk/log/20190428T093004Z.fail.html.gz -
09:03 PM Bug #15745: There is no symmetry in the beginless range and the endless range using `Range#inspect`
- mame (Yusuke Endoh) wrote:
> a beginless range has only one use case (DSL-like usage)
I'm not sure what you mean by DSL-like usage, but I wouldn't be surprised if many people use it like `array[..-2]` (instead of `array[0..-2]`).
In... -
12:17 PM Bug #15745: There is no symmetry in the beginless range and the endless range using `Range#inspect`
- Eregon (Benoit Daloze) wrote:
> Yes, I think it's a possibility and is rather consistent.
Agreed, it is the most consistent. IMHO, `p (1..) #=> 1..nil` is a bit verbose, though.
I think that an endless range will be much more com... -
11:42 AM Bug #15745: There is no symmetry in the beginless range and the endless range using `Range#inspect`
- Yes, I think it's a possibility and is rather consistent.
Otherwise, we need to special-case #inspect for beginless, endless and begin+endless ranges as you showed above.
I'd rather have a straightforward implementation for Range#ins... -
05:45 PM Bug #15808 (Rejected): Forwardable doesn't allow forwarding the 'print' message
- This is not a bug in Forwardable, this is due to the fact that OpenStruct doesn't override `print`, as `Kernel#print` is already defined. You must undefine the `print` method in OpenStruct if you want this to work. Example:
```ruby
... -
04:04 PM Bug #15808 (Rejected): Forwardable doesn't allow forwarding the 'print' message
- The following program forwards two messages to `@foo`: message 'print' and message 'bar'.
When I forward the 'print' message, I see a warning and the return value of `print` is always `nil`
(despite the fact that I specified my own ret... -
05:06 PM Misc #14632: [ANN] git.ruby-lang.org
- Today and yesterday I updated ruby-commit-hook to deal with race condition and corner cases of notifications, like pushing multiple commits at once. Now ruby-commit-hook should be correctly working for much more situations.
@nobu and ... -
04:56 PM Bug #15809 (Assigned): GC.verify_compaction_references - intermittent SEGV's on multiple platforms
-
04:48 PM Bug #15809 (Closed): GC.verify_compaction_references - intermittent SEGV's on multiple platforms
- See
https://travis-ci.org/ruby/ruby/jobs/525627187#L2684
https://ci.appveyor.com/project/ruby/ruby/builds/24138134/job/i7e441u7se11w7ey#L3402
Both have an error similar to:
```
/ruby/test/ruby/test_gc_compact.rb:128: [BUG] ROOT ... -
04:54 PM Revision dfc0eeb0 (git): Fully support Git in tool/merger.rb
- as both backport source repository and backport destination repository.
-
04:23 PM Revision f0776e32 (git): Add more debug print for random CI failure on osx Travis
- and remove `git status` with noisy rvm trace log
see r67347 -
04:17 PM Revision 50cbb21b (git): Add "Integer#[] with range" to NEWS
- 04:00 PM Revision 75260d36 (git): * remove trailing spaces.
-
03:59 PM Revision 991e3268 (git): tool/merger.rb: Avoid making too-deep indentation
- because it's hard to understand what's going on when indentation depth
is too deep.
Sorry for polluting git blame, but most of the Merger's lines are
updated recently anyway. -
03:53 PM Revision 2dddd370 (git): Support `tool/merger.rb removetag` under Git
- repository.
- 03:22 PM Revision bbad0d05 (git): * 2019-04-29
-
03:19 PM Revision fad2825e (git): Support `tool/merger.rb tag` under Git repository
-
02:42 PM Feature #8842 (Closed): Integer#[] with range
- Applied in changeset commit:git|6bedbf462544a7917fdc8d8c44276079a6e156cf.
----------
numeric.c: Extend Integer#[] to support range arguments
````
0b01001101[2, 4] #=> 0b0011
0b01001100[2..5] #=> 0b0011
0b01001100[2...6] #=> 0b0011
... - 02:42 PM Revision 555d1dda (git): * expand tabs.
-
02:40 PM Revision 6bedbf46 (git): numeric.c: Extend Integer#[] to support range arguments
- ````
0b01001101[2, 4] #=> 0b0011
0b01001100[2..5] #=> 0b0011
0b01001100[2...6] #=> 0b0011
^^^^
````
[Feature #8842] -
02:29 PM Bug #15807: Range#minmax is slow and never returns for endless ranges
- mame (Yusuke Endoh) wrote:
> `Range#max` is not consistent with `Enumerable#minmax`.
Thanks for pointing this out, I wasn't aware of that. Floats are another example:
``` ruby
(1..(5.5)).max # => 5.5
(1..(5.5)).minmax # => [1, 5]
... -
12:32 PM Bug #15807: Range#minmax is slow and never returns for endless ranges
- I'm never against fixing this issue but I have one concern. Currently, `Range#max` is not consistent with `Enumerable#minmax`.
```
p ("a".."aa").max #=> "aa"
p ("a".."aa").minmax #=> ["a", "z"]
```
Thus, if `Range#minmax` is... -
12:14 PM Bug #15807 (Closed): Range#minmax is slow and never returns for endless ranges
- current situation:
- `(1..).minmax` runs forever
- `(1..).max` raises "cannot get the maximum of endless range"
- `(1..Float::INFINITY).minmax` runs forever
- `(1..Float::INFINITY).max` returns instantly
- `(1..1_000_000_000).minm... -
02:23 PM Revision cb550246 (git): test/ruby/test_integer.rb: Add a sane test for Integer#[]
-
01:53 PM Revision 3bc81033 (git): Support `tool/merger.rb up` under Git repository
- updating indentation (and slightly changing styles) for areas already
supporting Git. -
01:25 PM Revision d906dd87 (git): Skip CLOCK_UPTIME_RAW_APPROX since it seems less precise than advertised on macOS
- * See https://travis-ci.org/ruby/ruby/jobs/525595997
-
01:15 PM Revision 392d84b4 (git): Fix wrong svn options
- for SVN as a backport source.
This was a mistake in de5378233b2ff5434f024ac66285e699794a321d... -
01:02 PM Revision 1c8cefca (git): Stop using global variable for repos
- to avoid having impact from other places.
-
12:59 PM Revision 9426da83 (git): Exclude failing Process.clock_getres specs on AIX
-
12:55 PM Revision a27f7e49 (git): Add missing platform guard
-
12:55 PM Revision 9a0dbb34 (git): Skip problematic Process.clock_getres specs on ARM
- * https://rubyci.org/logs/rubyci.s3.amazonaws.com/scw-9d6766/ruby-trunk/log/20190428T051708Z.fail.html.gz
* https://rubyci.org/logs/rubyci.s3.amazonaws.com/scw-ad7f67/ruby-trunk/log/20190428T045405Z.fail.html.gz -
12:54 PM Feature #15804: A generic method to resolve the indexing on a sequence
- I'm unsure how many cases people want to implement the index resolving code, but if it is not rare, I'm for the proposal.
I don't think that we will often add a new concept (like begin/end-less Ranges) that affects the resolving code,... -
12:53 PM Revision cb8eb373 (git): Now tool/merger.rb may use Git [ci skip]
-
12:51 PM Revision f2d7ba6a (git): make sync-default-gems GEM=irb
- from https://github.com/ruby/irb/commit/e8e79d569ed59fe4ed4fbca968917ce799f02a5e.
This colorizes Range object on IRB inspect. -
12:44 PM Revision 13abf551 (git): Workaround a CentOS bug in Process.clock_getres specs
-
12:41 PM Revision 14965c5f (git): Drop SVN-specific method from Merger module
- to clarify it's not needed for Git support.
-
12:41 PM Revision fcb18755 (git): Make Merger.version private to the module
- because it's not used outside the Module.
-
12:36 PM Revision 16695af0 (git): Refactor logic in Process.clock_gettime spec
-
12:35 PM Revision fc37a045 (git): Fix typo in spec
-
12:08 PM Revision d835ed4d (git): Define merger.rb's methods under Merger namespace
- so that we do not monkey-patch all classes by defining methods on
top-level (Object class).
Not arranging indentation in it to keep `git blame` for now. -
11:34 AM Revision 8711f77a (git): make sync-default-gems GEM=irb
- from https://github.com/ruby/irb/commit/96f05e726879e9858eb015c8d043c9f52b864ff9.
Just syncing newer test changes so that conflicts do not happen when trunk is
modified and we need to backport that to ruby/irb. -
11:18 AM Revision 588f212c (git): make sync-default-gems GEM=irb
- from https://github.com/ruby/irb/commit/44301d382794d91e2caa16dd4efe62439e0041d8.
This includes some fixes for string interpolation highlight fixes. -
11:17 AM Revision 4d8ad48f (git): Support git as redmine-backporter's done destination
-
10:37 AM Revision 5d24fba5 (git): Skip the entire Process.clock_getres spec on FreeBSD
- * Clocks don't match the reported precision.
* https://rubyci.org/logs/rubyci.s3.amazonaws.com/freebsd11zfs/ruby-trunk/log/20190428T093003Z.fail.html.gz -
05:10 AM Revision f40458e9 (git): Specify VM_CHECK_MODE explicitly
- In my understanding, `VM_CHECK_MODE` should be Integer and I'm not sure
how `-DVM_CHECK_MODE` would behave. To make the matters simple, let me
pass the mode explicitly. -
05:04 AM Revision 766293fc (git): Ruby 2.3 is EOL
-
04:46 AM Revision 4c8f1078 (git): Make the range to export as changelog optional
- * `from` is defaulted to the beginning of the branch inclusively,
otherwise the given revision is excluded as the previous.
* `to` is defaulted to the head. -
04:06 AM Feature #15797: Use realpath(3) instead of custom realpath implementation if available
- akr (Akira Tanaka) wrote:
> PATH_MAX is dangerous.
> ...
I'm not sure if this is still a problem on modern Linux, but here's an updated patch that passes a NULL pointer as the second argument to realpath(3), and then frees the pointer ... -
03:37 AM Feature #15797: Use realpath(3) instead of custom realpath implementation if available
- PATH_MAX is dangerous.
Quotes from http://man7.org/linux/man-pages/man3/realpath.3.html
```
BUGS
The POSIX.1-2001 standard version of this function is broken by
design, since it is impossible to determine a suitabl... -
03:23 AM Feature #15797: Use realpath(3) instead of custom realpath implementation if available
- Attached is an updated patch against trunk, now that the taint fix in #15803 was committed. One other change in this patch is that the `realpath_rec` function is no longer compiled if the native realpath(3) implementation is used.
-
03:11 AM Revision d72bd190 (git): Added VCS::SVN#branch_beginning
-
03:04 AM Revision b7669705 (git): Search the beginning revision more strictly a bit
-
02:36 AM Revision fdcd6405 (git): Makefiles need to be indented by tabs
-
02:36 AM Revision 5a53682d (git): Removed `--reverse` option
- It is nonsense with `-n1` option.
-
02:17 AM Bug #15803 (Closed): File.realpath should always return a tainted string
- Committed at a15f7dd1fb1148c3d586238ee6907875f2e40379
-
02:07 AM Revision d0a54673 (git): Update rubygems with latest upstream changes
- Closes: https://github.com/ruby/ruby/pull/2154
-
01:47 AM Revision a15f7dd1 (git): Always mark the string returned by File.realpath as tainted
- This string can include elements that were not in either string
passed to File.realpath, even if one of the strings is an
absolute path, due to symlinks:
```ruby
Dir.mkdir('b') unless File.directory?('b')
File.write('b/a', '') unless Fi... -
01:41 AM Revision d47cd75b (git): Chomp a newline from the branch name
-
01:26 AM Feature #15799: pipeline operator
- duerst (Martin Dürst) wrote:
> As for the assignment, just using parentheses looks confusing to me. It's clear we can't use `>=` or `|=`, but `|>=` or some other combination would be much clearer than just parentheses.
OK, I separate... -
12:56 AM Revision 7790b610 (git): Shorten git revision name without "r" prefix in snapshot