Unable to add package Oceananigans.jl

I have Julia v1.6.1 and I have tried to add Oceananigans package inside it but I am getting git errors that I am unable to crack. Here is the full error message-

julia> using Pkg

julia> Pkg.add("Oceananigans"); Pkg.status(); pkg"st --manifest"'
    Updating registry at `~/.julia/registries/General`
β”Œ Warning: could not download https://pkg.julialang.org/registries
β”” @ Pkg.Types /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/Types.jl:980
   Resolving package versions...
     Cloning [4fba245c-0d91-5ea0-9b3e-6abc04ee57a9] ArrayInterface from https://github.com/JuliaArrays/ArrayInterface.jl.git
ERROR: failed to clone from https://github.com/JuliaArrays/ArrayInterface.jl.git, error: GitError(Code:ERROR, Class:OS, failed to connect to github.com: Connection timed out)
Stacktrace:
  [1] pkgerror(msg::String)
    @ Pkg.Types /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/Types.jl:55
  [2] clone(ctx::Pkg.Types.Context, url::String, source_path::String; header::String, credentials::Nothing, kwargs::Base.Iterators.Pairs{Symbol, Bool, Tuple{Symbol}, NamedTuple{(:isbare,), Tuple{Bool}}})
    @ Pkg.GitTools /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/GitTools.jl:119
  [3] #ensure_clone#2
    @ /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/GitTools.jl:72 [inlined]
  [4] install_git(ctx::Pkg.Types.Context, uuid::Base.UUID, name::String, hash::Base.SHA1, urls::Vector{String}, version::VersionNumber, version_path::String)
    @ Pkg.Operations /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/Operations.jl:642
  [5] download_source(ctx::Pkg.Types.Context, pkgs::Vector{Pkg.Types.PackageSpec}, urls::Dict{Base.UUID, Vector{String}}; readonly::Bool)
    @ Pkg.Operations /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/Operations.jl:832
  [6] #download_source#57
    @ /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/Operations.jl:730 [inlined]
  [7] download_source
    @ /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/Operations.jl:728 [inlined]
  [8] add(ctx::Pkg.Types.Context, pkgs::Vector{Pkg.Types.PackageSpec}, new_git::Vector{Base.UUID}; preserve::Pkg.Types.PreserveLevel, platform::Base.BinaryPlatforms.Platform)
    @ Pkg.Operations /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/Operations.jl:1233
  [9] add(ctx::Pkg.Types.Context, pkgs::Vector{Pkg.Types.PackageSpec}; preserve::Pkg.Types.PreserveLevel, platform::Base.BinaryPlatforms.Platform, kwargs::Base.Iterators.Pairs{Symbol, Base.TTY, Tuple{Symbol}, NamedTuple{(:io,), Tuple{Base.TTY}}})
    @ Pkg.API /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/API.jl:203
 [10] add(pkgs::Vector{Pkg.Types.PackageSpec}; io::Base.TTY, kwargs::Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
    @ Pkg.API /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/API.jl:79
 [11] add(pkgs::Vector{Pkg.Types.PackageSpec})
    @ Pkg.API /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/API.jl:77
 [12] #add#23
    @ /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/API.jl:75 [inlined]
 [13] add
    @ /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/API.jl:75 [inlined]
 [14] #add#22
    @ /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/API.jl:74 [inlined]
 [15] add(pkg::String)
    @ Pkg.API /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/API.jl:74
 [16] top-level scope
    @ REPL[2]:1

caused by: GitError(Code:ERROR, Class:OS, failed to connect to github.com: Connection timed out)
Stacktrace:
  [1] macro expansion
    @ /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/LibGit2/src/error.jl:110 [inlined]
  [2] clone(repo_url::SubString{String}, repo_path::String, clone_opts::LibGit2.CloneOptions)
    @ LibGit2 /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/LibGit2/src/repository.jl:459
  [3] clone(repo_url::SubString{String}, repo_path::String; branch::String, isbare::Bool, remote_cb::Ptr{Nothing}, credentials::LibGit2.CachedCredentials, callbacks::Dict{Symbol, Tuple{Ptr{Nothing}, Any}})
    @ LibGit2 /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/LibGit2/src/LibGit2.jl:583
  [4] clone(ctx::Pkg.Types.Context, url::String, source_path::String; header::String, credentials::Nothing, kwargs::Base.Iterators.Pairs{Symbol, Bool, Tuple{Symbol}, NamedTuple{(:isbare,), Tuple{Bool}}})
    @ Pkg.GitTools /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/GitTools.jl:109
  [5] #ensure_clone#2
    @ /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/GitTools.jl:72 [inlined]
  [6] install_git(ctx::Pkg.Types.Context, uuid::Base.UUID, name::String, hash::Base.SHA1, urls::Vector{String}, version::VersionNumber, version_path::String)
    @ Pkg.Operations /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/Operations.jl:642
  [7] download_source(ctx::Pkg.Types.Context, pkgs::Vector{Pkg.Types.PackageSpec}, urls::Dict{Base.UUID, Vector{String}}; readonly::Bool)
    @ Pkg.Operations /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/Operations.jl:832
  [8] #download_source#57
    @ /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/Operations.jl:730 [inlined]
  [9] download_source
    @ /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/Operations.jl:728 [inlined]
 [10] add(ctx::Pkg.Types.Context, pkgs::Vector{Pkg.Types.PackageSpec}, new_git::Vector{Base.UUID}; preserve::Pkg.Types.PreserveLevel, platform::Base.BinaryPlatforms.Platform)
    @ Pkg.Operations /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/Operations.jl:1233
 [11] add(ctx::Pkg.Types.Context, pkgs::Vector{Pkg.Types.PackageSpec}; preserve::Pkg.Types.PreserveLevel, platform::Base.BinaryPlatforms.Platform, kwargs::Base.Iterators.Pairs{Symbol, Base.TTY, Tuple{Symbol}, NamedTuple{(:io,), Tuple{Base.TTY}}})
    @ Pkg.API /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/API.jl:203
 [12] add(pkgs::Vector{Pkg.Types.PackageSpec}; io::Base.TTY, kwargs::Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
    @ Pkg.API /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/API.jl:79
 [13] add(pkgs::Vector{Pkg.Types.PackageSpec})
    @ Pkg.API /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/API.jl:77
 [14] #add#23
    @ /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/API.jl:75 [inlined]
 [15] add
    @ /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/API.jl:75 [inlined]
 [16] #add#22
    @ /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/API.jl:74 [inlined]
 [17] add(pkg::String)
    @ Pkg.API /jobfs/24705507.gadi-pbs/0/julia/1.6.1/source/julia/usr/share/julia/stdlib/v1.6/Pkg/src/API.jl:74
 [18] top-level scope
    @ REPL[2]:1

Can anyone please help me to get out of this. Thank you in advance!

You are using Windows, yes? Can you clone a repo manually in a shell?

@gustaphe, I am using linux os using Virtual box. But I am using this julia at one of the compute node of supercomputer facility. Could my local os can create this issue?
I had tried cloning manually-

[ss1986@gadi-gpu-v100-0093 Test]$ git clone https://github.com/JuliaArrays/ArrayInterface.jl.git
Cloning into 'ArrayInterface.jl'...
fatal: unable to access 'https://github.com/JuliaArrays/ArrayInterface.jl.git/': Failed to connect to github.com port 443: Connection timed out

I would guess firewall issue. Not a lot of experience with cluster computing or network issues though.

It could be that the compute nodes don’t have access to the internet. Best would be to inquire with system administratos about how to install software in them. You would usually install packages from the access nodes, and not from compute nodes.

1 Like