-
Notifications
You must be signed in to change notification settings - Fork 848
Description
Dear Colab team,
I am have enjoyed using colab as a pro subscriber for several years now — both as an education tool for my students, as well as for research. I also loved using it for internal development when I worked at DeepMind.
I would like to report an issue that the latest update to the VM used by Google Colab appears to break all compatibility with JuliaLang, over all versions of Julia that I have tested, and on both CPU and GPU runtimes. This includes Python libraries which use Julia as a dependency.
Background
Julia can both be used in Colab a dependency of various Python libraries, as well as through PyJulia, as well as used directly by replacing the default Jupyter kernel (e.g., @ageron's julia examples). (Some interesting trivia: Jupyter actually stands for Ju(lia)pyt(hon)e(R) - the three languages initially supported by Jupyter.)
Now of course I understand that only Python is officially supported, but regardless, Julia has very large numerical computing ecosystem with many libraries of interest to both colab subscribers and Google Cloud clients in general, and is a dependency of several Python libraries. For the past several years it has been possible to install Julia on any Colab runtime without issue – useful for research and education. (A nice example of this is the examples for AlphaZero.jl — which are now unfortunately broken).
For example, tomorrow I am teaching a symbolic ML tutorial at MIT to nearly 100 ugrad/grad students, and while I had planned to use Colab (which, from Google's perspective, would probably be a great way to increase academic interest in Google Cloud!), I had to switch last-minute to using an inferior alternative instead, because colab is now generating errors (MilesCranmer/PySR#259).
MWE
Launching a Julia binary installed from any channel ("jill", "juliaup", or simply a tarball) seems to result in errors related to shared library incompatibility. Even the one accessible via apt-get install julia seems to result in such errors.
I note that all of these examples used to work. It is only in the last month or so when colab updated the VM did these errors start appearing – even for older versions of Julia. I don't quite understand why it has broken, because these binaries are compatible on such a wide range of linux distributions.
Here is a MWE (colab here)
%%shell
set -x
wget -nv https://julialang-s3.julialang.org/bin/linux/x64/1.8/julia-1.8.5-linux-x86_64.tar.gz -O /tmp/julia.tar.gz
tar -xzf /tmp/julia.tar.gz -C /usr/local/ --strip-components 1
rm /tmp/julia.tar.gzfollowed by
!julia -e 'println("Hello World!")'This generates the following output:
Hello World!
munmap_chunk(): invalid pointer
signal (6): Aborted
in expression starting at none:0
gsignal at /lib/x86_64-linux-gnu/libc.so.6 (unknown line)
abort at /lib/x86_64-linux-gnu/libc.so.6 (unknown line)
unknown function (ip: 0x7fa7f1a1a26d)
unknown function (ip: 0x7fa7f1a222fb)
unknown function (ip: 0x7fa7f1a2254b)
close_unit_1 at /workspace/srcdir/gcc-12.1.0/libgfortran/io/unit.c:742
close_units at /workspace/srcdir/gcc-12.1.0/libgfortran/io/unit.c:800
unknown function (ip: 0x7fa7f1dcff6a)
unknown function (ip: 0x7fa7f19d38a6)
exit at /lib/x86_64-linux-gnu/libc.so.6 (unknown line)
main at julia (unknown line)
__libc_start_main at /lib/x86_64-linux-gnu/libc.so.6 (unknown line)
unknown function (ip: 0x401098)
Allocations: 2907 (Pool: 2895; Big: 12); GC: 0Similar errors related to shared libraries seem reproducible in versions going back to 1.4 of Julia.
Impacted projects
Here are some related issues in projects that have been impacted:
- Broken inside Google Colab JuliaLang/julia#48461
- [BUG] Colab broken on current Julia version MilesCranmer/PySR#259
- How to use GR_jll in Google Colab? JuliaPackaging/Yggdrasil#6089
- Install breaking on latest colab update johnnychen94/colab-julia-bootstrap#4
- Installation bug (?) in Colab ageron/julia_notebooks#4
- Having trouble using AlphaZero.jl in Google Colab jonathan-laurent/AlphaZero.jl#155
- Is there a way to use AlphaZero.jl without using Plots.jl and Gr_jll? jonathan-laurent/AlphaZero.jl#160
- Julia forum post: https://discourse.julialang.org/t/google-colab-compatibility-broken/93004?u=milescranmer
These are just the issues I have seen, there are likely many others.
This is a major issue for many projects in the Julia ecosystem, including my own, so I'm happy to help you in any way with respect to solving this bug. Let me know what else I can do to provide insight into these bugs.
Thank you.
Best regards,
Miles