Project

General

Profile

Actions

Bug #11088

closed

On Exception too expensive inspect is called on recursive object graph with 3000 elements in it, swallows memory and ultimately doesn't deliver exception

Added by kaiserprogrammer (Jürgen Bickert) over 6 years ago. Updated about 6 years ago.

Status:
Rejected
Priority:
Normal
Assignee:
-
Target version:
-
ruby -v:
ruby 2.2.2p95 (2015-04-13 revision 50295) [x86_64-linux]
[ruby-core:68965]

Description

I have tested with simple cases where the dumped structure is not recursive and it works fine. So I attached a non-working dump which will when called with inspect or a non-existing method run off in an infinite loop.

When you run "ruby bug_hunt.rb" it will get stuck and you have to abort(CTRL-C) and only then will it print an error message and finish.


Files

bug_hunt.rb (336 Bytes) bug_hunt.rb kaiserprogrammer (Jürgen Bickert), 04/23/2015 12:33 AM
ruby_object.dump (561 KB) ruby_object.dump Marshal.dump kaiserprogrammer (Jürgen Bickert), 04/23/2015 12:33 AM
11088_test.rb (305 Bytes) 11088_test.rb shishir127 (Shishir Joshi), 05/09/2015 06:57 AM
simple-inspect.txt (1.19 MB) simple-inspect.txt austin (Austin Ziegler), 05/10/2015 02:06 AM
simple-inspect-stats.txt (90.7 KB) simple-inspect-stats.txt austin (Austin Ziegler), 05/10/2015 02:07 AM
bug_hunt_benchmark.rb (1.42 KB) bug_hunt_benchmark.rb austin (Austin Ziegler), 05/10/2015 02:30 AM
bug_hunt_simple.rb (1.09 KB) bug_hunt_simple.rb austin (Austin Ziegler), 05/10/2015 02:31 AM
Actions

Also available in: Atom PDF