GNU bug report logs - #61121
Cannot import IJulia in Julia

Previous Next

Package: guix;

Reported by: Theodore Ehrenborg <theodore.ehrenborg <at> gmail.com>

Date: Sat, 28 Jan 2023 13:46:01 UTC

Severity: normal

Done: Efraim Flashner <efraim <at> flashner.co.il>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Efraim Flashner <efraim <at> flashner.co.il>
Cc: tracker <at> debbugs.gnu.org
Subject: bug#61121: closed (Cannot import IJulia in Julia)
Date: Thu, 09 Feb 2023 14:54:01 +0000
[Message part 1 (text/plain, inline)]
Your message dated Thu, 9 Feb 2023 16:53:01 +0200
with message-id <Y+UIzdetrRVjOdxZ <at> 3900XT>
and subject line Re: bug#61121: Cannot import IJulia in Julia
has caused the debbugs.gnu.org bug report #61121,
regarding Cannot import IJulia in Julia
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)


-- 
61121: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=61121
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Theodore Ehrenborg <theodore.ehrenborg <at> gmail.com>
To: bug-guix <at> gnu.org
Subject: Cannot import IJulia in Julia
Date: Sat, 28 Jan 2023 13:45:00 +0000
[Message part 3 (text/plain, inline)]
Hi Guix,

I would like to run a Jupyter notebook using Julia, so I need to install
the IJulia backend:

guix install julia
julia # Enter julia REPL
] # To go into the julia pkg REPL
add IJulia
# Now type backspace to go to julia REPL
using IJulia

This produces the error:

[ Info: Precompiling IJulia [7073ff75-c697-5162-941a-fcdaad2a7d2a]
ERROR: LoadError: InitError: SystemError: opening file
"/gnu/store/npj8z0g9nx14wl22yphqfs2c5w4qk5jk-julia-1.8.3/share/julia/cert.pem":
No such file or directory

The full error message is here: https://pastebin.com/qC8yyHXT

I saw a very similar bug on Gentoo:

Without this file (which can be a symbolic link to
`/etc/ssl/certs/ca-certificates.crt`) many Julia 1.8.3 packages, e.g.
`HTTP`, do not work.
This is what happens:

julia> import HTTP
[ Info: Precompiling HTTP [cd3eb016-35fb-5094-929b-558a96fad6f3]
ERROR: LoadError: InitError: SystemError: opening file
"/usr/share/julia/cert.pem":

(https://bugs.gentoo.org/888978)

Any help would be greatly appreciated.

Best regards,
Theodore Ehrenborg
[Message part 4 (text/html, inline)]
[Message part 5 (message/rfc822, inline)]
From: Efraim Flashner <efraim <at> flashner.co.il>
To: Simon Tournier <zimon.toutoune <at> gmail.com>
Cc: 61121-done <at> debbugs.gnu.org,
 Theodore Ehrenborg <theodore.ehrenborg <at> gmail.com>
Subject: Re: bug#61121: Cannot import IJulia in Julia
Date: Thu, 9 Feb 2023 16:53:01 +0200
[Message part 6 (text/plain, inline)]
On Tue, Jan 31, 2023 at 12:34:16PM +0100, Simon Tournier wrote:
> 
> --8<---------------cut here---------------start------------->8---
> function __init__()
>     global artifact_dir = dirname(Sys.BINDIR)
>     global cacert = normpath(Sys.BINDIR, Base.DATAROOTDIR, "julia", "cert.pem")
> end
> --8<---------------cut here---------------end--------------->8---

I've changed this line to:

global cacert = get(ENV, \"SSL_CERT_FILE\", "\"/etc/ssl/certs/ca-certificates.crt\")

and then tested it with the example at the beginning of the bug report.

> Well, somehow turn back these tests:
> 
> --8<---------------cut here---------------start------------->8---
>              ;; julia embeds a certificate, we are not doing that
>              (substitute* "stdlib/MozillaCACerts_jll/test/runtests.jl"
>                (("@test isfile\\(MozillaCACerts_jll.cacert\\)")
>                 "@test_broken isfile(MozillaCACerts_jll.cacert)"))
>              ;; since certificate is not present some tests are failing in network option
>              (substitute* "usr/share/julia/stdlib/v1.8/NetworkOptions/test/runtests.jl"
>                (("@test isfile\\(bundled_ca_roots\\(\\)\\)")
>                 "@test_broken isfile(bundled_ca_roots())")
>                (("@test ispath\\(ca_roots_path\\(\\)\\)")
>                 "@test_broken ispath(ca_roots_path())")
>                (("@test ca_roots_path\\(\\) \\!= bundled_ca_roots\\(\\)")
>                 "@test_broken ca_roots_path() != bundled_ca_roots()"))
> --8<---------------cut here---------------end--------------->8---

I wasn't able to turn these tests back on though.

-- 
Efraim Flashner   <efraim <at> flashner.co.il>   אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted
[signature.asc (application/pgp-signature, inline)]

This bug report was last modified 2 years and 161 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.