iruby 0.8.1 → 0.8.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yml +5 -2
- data/CHANGES.md +8 -0
- data/Gemfile +3 -0
- data/README.md +19 -27
- data/iruby.gemspec +10 -2
- data/lib/iruby/application.rb +1 -1
- data/lib/iruby/display.rb +1 -1
- data/lib/iruby/ostream.rb +4 -0
- data/lib/iruby/session_adapter.rb +1 -1
- data/lib/iruby/version.rb +1 -1
- data/run-test.sh +1 -1
- data/test/integration_test.rb +1 -1
- metadata +13 -21
- data/ext/Rakefile +0 -19
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4f389a45d763afc30ae093cb65b479b727bde7f1a4ecf04246329f56099ec280
|
4
|
+
data.tar.gz: 16dc91aaba973d5b0e8cc4c2d9444266c9c8f479704a5394103a732f2f70ba01
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a2fcf2691c1f795abad87a5bfe174f17dd49980c11a6ffc1c3fc665e4345cf14caf3be273ff6123224864d261b9b6b730c9bd16907dcd535d2a168ce07f6763a
|
7
|
+
data.tar.gz: 523123ce6314e0f5e5e49dc0156dd00e6d3aac45b49af8780009df1977c7edd3306388ed2b3375a315ed5267da0c2311a6da21bbd0fffae58ef8fe19a8079ce6
|
data/.github/workflows/ci.yml
CHANGED
@@ -68,7 +68,10 @@ jobs:
|
|
68
68
|
GEMFILE
|
69
69
|
BUNDLE_GEMFILE=Gemfile.irb bundle install --jobs 4 --retry 3
|
70
70
|
|
71
|
-
-
|
71
|
+
- name: Install IRuby gem
|
72
|
+
run: |
|
73
|
+
gem install rubygems-requirements-system
|
74
|
+
gem install pkg/*.gem
|
72
75
|
|
73
76
|
- run: ruby -r iruby -e "p IRuby::SessionAdapter.select_adapter_class"
|
74
77
|
env:
|
@@ -133,7 +136,7 @@ jobs:
|
|
133
136
|
|
134
137
|
- run: rake build
|
135
138
|
|
136
|
-
- run: gem install pkg/*.gem
|
139
|
+
- run: gem install rubygems-requirements-system pkg/*.gem
|
137
140
|
|
138
141
|
- run: ruby -r iruby -e "p IRuby::SessionAdapter.select_adapter_class"
|
139
142
|
env:
|
data/CHANGES.md
CHANGED
@@ -1,3 +1,11 @@
|
|
1
|
+
# 0.8.2 (2025-04-10)
|
2
|
+
|
3
|
+
* Update CI to refresh apt packages before installing IRuby gem by @kojix2 in https://github.com/SciRuby/iruby/pull/367
|
4
|
+
* Fix missing `OStream#closed?` method by @RobinDaugherty in https://github.com/SciRuby/iruby/pull/368
|
5
|
+
* Use rubygems-requirements-system to install system dependencies automatically by @kou in https://github.com/SciRuby/iruby/pull/369
|
6
|
+
* Various typo corrections by @kojix2 in https://github.com/SciRuby/iruby/pull/370
|
7
|
+
* Minor changes to README by @kojix2 in https://github.com/SciRuby/iruby/pull/371
|
8
|
+
|
1
9
|
# 0.8.1 (2025-02-16)
|
2
10
|
|
3
11
|
* Add support for jupyter widgets by @matt-do-it in https://github.com/SciRuby/iruby/pull/350
|
data/Gemfile
CHANGED
data/README.md
CHANGED
@@ -4,7 +4,7 @@
|
|
4
4
|
[](https://github.com/SciRuby/iruby/actions)
|
5
5
|
[](https://mybinder.org/v2/gh/RubyData/binder/master?filepath=ruby-data.ipynb)
|
6
6
|
|
7
|
-
IRuby is a Ruby kernel for [Jupyter project](
|
7
|
+
IRuby is a Ruby kernel for [Jupyter project](https://jupyter.org/).
|
8
8
|
|
9
9
|
## Try IRuby
|
10
10
|
|
@@ -20,54 +20,44 @@ The following URL launches JupyterLab directly on Binder.
|
|
20
20
|
|
21
21
|
### Requirements
|
22
22
|
|
23
|
-
|
23
|
+
- [Jupyter](https://jupyter.org)
|
24
24
|
|
25
25
|
The following requirements are automatically installed.
|
26
26
|
|
27
|
-
|
28
|
-
|
27
|
+
- [ffi-rzmq](https://github.com/chuckremes/ffi-rzmq)
|
28
|
+
- [libzmq](https://github.com/zeromq/libzmq)
|
29
29
|
|
30
30
|
The following dependencies are optional.
|
31
31
|
|
32
|
-
|
32
|
+
- [Pry][Pry], if you want to use [Pry][Pry] instead of IRB for the code execution backend
|
33
33
|
|
34
34
|
### Installing Jupyter Notebook and/or JupyterLab
|
35
35
|
|
36
36
|
See the official document to know how to install Jupyter Notebook and/or JupyterLab.
|
37
37
|
|
38
|
-
|
39
|
-
|
38
|
+
- <https://jupyter.readthedocs.io/en/latest/install/notebook-classic.html>
|
39
|
+
- <https://jupyter.readthedocs.io/en/latest/install.html>
|
40
40
|
|
41
41
|
### Ubuntu
|
42
42
|
|
43
|
-
#### Ubuntu
|
43
|
+
#### Ubuntu 22.04+
|
44
44
|
|
45
45
|
```shell
|
46
46
|
sudo apt install libtool libffi-dev ruby ruby-dev make
|
47
47
|
|
48
|
-
gem install --user-install
|
49
|
-
iruby register --force
|
50
|
-
```
|
51
|
-
|
52
|
-
#### Ubuntu 16
|
53
|
-
|
54
|
-
The latest IRuby requires Ruby >= 2.4 while Ubuntu's official Ruby package is version 2.3.
|
55
|
-
So you need to install Ruby >= 2.4 by yourself before preparing IRuby.
|
56
|
-
We recommend to use rbenv.
|
57
|
-
|
58
|
-
```shell
|
59
|
-
sudo apt install libtool libffi-dev ruby ruby-dev make
|
48
|
+
gem install --user-install rubygems-requirements-system
|
60
49
|
gem install --user-install iruby
|
61
50
|
iruby register --force
|
62
51
|
```
|
63
52
|
|
64
53
|
### Fedora
|
65
54
|
|
66
|
-
#### Fedora
|
55
|
+
#### Fedora 40+
|
67
56
|
|
68
57
|
```shell
|
69
58
|
sudo dnf install ruby ruby-dev make zeromq-devel
|
70
59
|
|
60
|
+
gem install --user-install rubygems-requirements-system
|
71
61
|
gem install --user-install iruby
|
72
62
|
iruby register --force
|
73
63
|
```
|
@@ -89,6 +79,7 @@ Install Jupyter.
|
|
89
79
|
#### Homebrew
|
90
80
|
|
91
81
|
```shell
|
82
|
+
gem install rubygems-requirements-system
|
92
83
|
gem install iruby
|
93
84
|
iruby register --force
|
94
85
|
```
|
@@ -99,6 +90,7 @@ If you are using macports, run the following commands.
|
|
99
90
|
|
100
91
|
```shell
|
101
92
|
port install libtool autoconf automake autogen
|
93
|
+
gem install rubygems-requirements-system
|
102
94
|
gem install iruby
|
103
95
|
iruby register --force
|
104
96
|
```
|
@@ -116,8 +108,8 @@ docker run --rm -it -p 8888:8888 rubydata/datascience-notebook
|
|
116
108
|
|
117
109
|
You can use Java classes in your IRuby notebook.
|
118
110
|
|
119
|
-
|
120
|
-
|
111
|
+
- JRuby version >= 9.0.4.0
|
112
|
+
- iruby gem
|
121
113
|
|
122
114
|
After installation, make sure that your `env` is set up to use jruby.
|
123
115
|
|
@@ -160,8 +152,8 @@ export IRUBY_SESSION_ADAPTER="cztop"
|
|
160
152
|
|
161
153
|
There are two backends: PlainBackend and PryBackend.
|
162
154
|
|
163
|
-
|
164
|
-
|
155
|
+
- PlainBackend is the default backend. It uses [IRB](https://github.com/ruby/irb).
|
156
|
+
- PryBackend uses [Pry][Pry].
|
165
157
|
|
166
158
|
You can switch the backend to PryBackend by running the code below.
|
167
159
|
|
@@ -171,9 +163,9 @@ IRuby::Kernel.instance.switch_backend!(:pry)
|
|
171
163
|
|
172
164
|
## Notebooks
|
173
165
|
|
174
|
-
Take a look at the [example notebook](
|
166
|
+
Take a look at the [example notebook](https://nbviewer.jupyter.org/urls/raw.github.com/SciRuby/sciruby-notebooks/master/getting_started.ipynb)
|
175
167
|
and the [collection of notebooks](https://github.com/SciRuby/sciruby-notebooks/) which includes a Dockerfile to create a containerized installation of iruby
|
176
|
-
and other scientific gems.
|
168
|
+
and other scientific gems.
|
177
169
|
|
178
170
|
## Contributing
|
179
171
|
|
data/iruby.gemspec
CHANGED
@@ -15,7 +15,6 @@ Gem::Specification.new do |s|
|
|
15
15
|
s.executables = %w[iruby]
|
16
16
|
s.test_files = s.files.grep(%r{^test/})
|
17
17
|
s.require_paths = %w[lib]
|
18
|
-
s.extensions = %w[ext/Rakefile]
|
19
18
|
|
20
19
|
s.required_ruby_version = '>= 2.3.0'
|
21
20
|
|
@@ -25,12 +24,21 @@ Gem::Specification.new do |s|
|
|
25
24
|
s.add_dependency 'logger'
|
26
25
|
s.add_dependency 'mime-types', '>= 3.3.1'
|
27
26
|
s.add_dependency 'multi_json', '~> 1.11'
|
28
|
-
s.add_dependency 'native-package-installer'
|
29
27
|
|
30
28
|
s.add_development_dependency 'pycall', '>= 1.2.1'
|
31
29
|
s.add_development_dependency 'rake'
|
32
30
|
s.add_development_dependency 'test-unit'
|
33
31
|
s.add_development_dependency 'test-unit-rr'
|
34
32
|
|
33
|
+
[
|
34
|
+
['arch_linux', 'zeromq'],
|
35
|
+
['debian', 'libzmq3-dev'],
|
36
|
+
['freebsd', 'libzmq4'],
|
37
|
+
['homebrew', 'zmq'],
|
38
|
+
['macports', 'zmq'],
|
39
|
+
].each do |platform, package|
|
40
|
+
s.requirements << "system: libzmq: #{platform}: #{package}"
|
41
|
+
end
|
42
|
+
|
35
43
|
s.metadata['msys2_mingw_dependencies'] = 'zeromq'
|
36
44
|
end
|
data/lib/iruby/application.rb
CHANGED
data/lib/iruby/display.rb
CHANGED
@@ -7,7 +7,7 @@ module IRuby
|
|
7
7
|
"text/markdown" => :to_markdown,
|
8
8
|
"image/svg+xml" => :to_svg,
|
9
9
|
"image/png" => :to_png,
|
10
|
-
"
|
10
|
+
"application/pdf" => :to_pdf,
|
11
11
|
"image/jpeg" => :to_jpeg,
|
12
12
|
"text/latex" => [:to_latex, :to_tex],
|
13
13
|
# NOTE: Do not include the entry of "application/json" because
|
data/lib/iruby/ostream.rb
CHANGED
data/lib/iruby/version.rb
CHANGED
data/run-test.sh
CHANGED
data/test/integration_test.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: iruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.8.
|
4
|
+
version: 0.8.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Daniel Mendler
|
8
8
|
- The SciRuby developers
|
9
|
+
autorequire:
|
9
10
|
bindir: exe
|
10
11
|
cert_chain: []
|
11
|
-
date: 2025-
|
12
|
+
date: 2025-04-10 00:00:00.000000000 Z
|
12
13
|
dependencies:
|
13
14
|
- !ruby/object:Gem::Dependency
|
14
15
|
name: data_uri
|
@@ -94,20 +95,6 @@ dependencies:
|
|
94
95
|
- - "~>"
|
95
96
|
- !ruby/object:Gem::Version
|
96
97
|
version: '1.11'
|
97
|
-
- !ruby/object:Gem::Dependency
|
98
|
-
name: native-package-installer
|
99
|
-
requirement: !ruby/object:Gem::Requirement
|
100
|
-
requirements:
|
101
|
-
- - ">="
|
102
|
-
- !ruby/object:Gem::Version
|
103
|
-
version: '0'
|
104
|
-
type: :runtime
|
105
|
-
prerelease: false
|
106
|
-
version_requirements: !ruby/object:Gem::Requirement
|
107
|
-
requirements:
|
108
|
-
- - ">="
|
109
|
-
- !ruby/object:Gem::Version
|
110
|
-
version: '0'
|
111
98
|
- !ruby/object:Gem::Dependency
|
112
99
|
name: pycall
|
113
100
|
requirement: !ruby/object:Gem::Requirement
|
@@ -169,8 +156,7 @@ email:
|
|
169
156
|
- mail@daniel-mendler.de
|
170
157
|
executables:
|
171
158
|
- iruby
|
172
|
-
extensions:
|
173
|
-
- ext/Rakefile
|
159
|
+
extensions: []
|
174
160
|
extra_rdoc_files: []
|
175
161
|
files:
|
176
162
|
- ".github/workflows/ci.yml"
|
@@ -186,7 +172,6 @@ files:
|
|
186
172
|
- docker/setup.sh
|
187
173
|
- docker/test.sh
|
188
174
|
- exe/iruby
|
189
|
-
- ext/Rakefile
|
190
175
|
- iruby.gemspec
|
191
176
|
- lib/iruby.rb
|
192
177
|
- lib/iruby/application.rb
|
@@ -266,6 +251,7 @@ licenses:
|
|
266
251
|
- MIT
|
267
252
|
metadata:
|
268
253
|
msys2_mingw_dependencies: zeromq
|
254
|
+
post_install_message:
|
269
255
|
rdoc_options: []
|
270
256
|
require_paths:
|
271
257
|
- lib
|
@@ -279,8 +265,14 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
279
265
|
- - ">="
|
280
266
|
- !ruby/object:Gem::Version
|
281
267
|
version: '0'
|
282
|
-
requirements:
|
283
|
-
|
268
|
+
requirements:
|
269
|
+
- 'system: libzmq: arch_linux: zeromq'
|
270
|
+
- 'system: libzmq: debian: libzmq3-dev'
|
271
|
+
- 'system: libzmq: freebsd: libzmq4'
|
272
|
+
- 'system: libzmq: homebrew: zmq'
|
273
|
+
- 'system: libzmq: macports: zmq'
|
274
|
+
rubygems_version: 3.5.22
|
275
|
+
signing_key:
|
284
276
|
specification_version: 4
|
285
277
|
summary: Ruby Kernel for Jupyter
|
286
278
|
test_files:
|
data/ext/Rakefile
DELETED
@@ -1,19 +0,0 @@
|
|
1
|
-
task default: :all
|
2
|
-
|
3
|
-
task all: [:ensure_zeromq]
|
4
|
-
|
5
|
-
task :ensure_zeromq do
|
6
|
-
begin
|
7
|
-
require 'ffi-rzmq'
|
8
|
-
rescue LoadError
|
9
|
-
require 'native-package-installer'
|
10
|
-
unless NativePackageInstaller.install(arch_linux: 'zeromq',
|
11
|
-
debian: 'libzmq3-dev',
|
12
|
-
freebsd: 'libzmq4',
|
13
|
-
homebrew: 'zmq',
|
14
|
-
macports: 'zmq',
|
15
|
-
redhat: 'zeromq-devel')
|
16
|
-
raise 'Failed to install ZeroMQ'
|
17
|
-
end
|
18
|
-
end
|
19
|
-
end
|