From 19c981bae51c5c55d42e8829e5162cf7fb20148e Mon Sep 17 00:00:00 2001 From: kojix2 <2xijok@gmail.com> Date: Wed, 29 Jun 2022 15:14:20 +0900 Subject: [PATCH 1/2] Fix Gnuplot issues in Ruby 2.7 (#321) Supported by @znz --- lib/iruby/kernel.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/iruby/kernel.rb b/lib/iruby/kernel.rb index ffe581c..3bc68d0 100644 --- a/lib/iruby/kernel.rb +++ b/lib/iruby/kernel.rb @@ -218,7 +218,7 @@ def execute_request(msg) end events.trigger(:post_execute) - events.trigger(:post_run_cell, result) unless silent + events.trigger(:post_run_cell, result, **{}) unless silent @session.send(:reply, :execute_reply, content) end From 4aa44ca24a42cf690930b88da8cc0ca75aaf57d4 Mon Sep 17 00:00:00 2001 From: kojix2 <2xijok@gmail.com> Date: Wed, 6 Jul 2022 06:44:47 +0900 Subject: [PATCH 2/2] Added comment --- lib/iruby/kernel.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/iruby/kernel.rb b/lib/iruby/kernel.rb index 3bc68d0..a2cd652 100644 --- a/lib/iruby/kernel.rb +++ b/lib/iruby/kernel.rb @@ -218,6 +218,7 @@ def execute_request(msg) end events.trigger(:post_execute) + # **{} is for Ruby2.7. Gnuplot#to_hash returns an Array. events.trigger(:post_run_cell, result, **{}) unless silent @session.send(:reply, :execute_reply, content)