JuliaPackaging / WinRPM.jl

RPM-md processing library
Other
21 stars 44 forks source link

Pkg.build(IJulia) fails, and "Kernel error" always appears when running Jupyter notebook for Julia coding #115

Open LinZhang1004 opened 7 years ago

LinZhang1004 commented 7 years ago

I have downloaded Jupyter notebook from Anaconda so that I can code Python and Julia. After installation, Python coding is working fine, while Julia coding never works b/c the notebook always indicates "kernel error".

Typing where jupyter at the Windows command prompt, I was told

INFO: Could not find files for the given pattern(s).

I go ahead to add IJulia

julia> Pkg.add("IJulia")
INFO: Package IJulia is already installed

I think it is because this is a second time I run this. When when I run the following

ENV["JUPYTER"]=""
Pkg.build("IJulia")

Many errors come out:

julia> ENV["JUPYTER"]=""
""

julia> Pkg.build("IJulia")
INFO: Building Conda
INFO: Building MbedTLS
INFO: Building WinRPM
WARNING: skipping repodata/repomd.xml, not in cache -- call WinRPM.update() to d
ownload
WARNING: skipping repodata/repomd.xml, not in cache -- call WinRPM.update() to d
ownload
INFO: Downloading https://cache.julialang.org/http://download.opensuse.org/repos
itories/windows:/mingw:/win32/openSUSE_Leap_42.2/repodata/repomd.xml
WARNING: Unknown download failure, error code: 2148270094
WARNING: Retry 1/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win32/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 2/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win32/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 3/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win32/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 4/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win32/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 5/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win32/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: received error 0 while downloading https://cache.julialang.org/http://d
ownload.opensuse.org/repositories/windows:/mingw:/win32/openSUSE_Leap_42.2/repod
ata/repomd.xml
INFO: Downloading https://cache.julialang.org/http://download.opensuse.org/repos
itories/windows:/mingw:/win64/openSUSE_Leap_42.2/repodata/repomd.xml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 1/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win64/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 2/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win64/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 3/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win64/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 4/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win64/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 5/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win64/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: received error 0 while downloading https://cache.julialang.org/http://d
ownload.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_Leap_42.2/repod
ata/repomd.xml
INFO: Building ZMQ
WARNING: skipping repodata/repomd.xml, not in cache -- call WinRPM.update() to d
ownload
WARNING: skipping repodata/repomd.xml, not in cache -- call WinRPM.update() to d
ownload
INFO: Updating WinRPM package list
INFO: Downloading https://cache.julialang.org/http://download.opensuse.org/repos
itories/windows:/mingw:/win32/openSUSE_Leap_42.2/repodata/repomd.xml
WARNING: Unknown download failure, error code: 2148270094
WARNING: Retry 1/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win32/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 2/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win32/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 3/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win32/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 4/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win32/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 5/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win32/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: received error 0 while downloading https://cache.julialang.org/http://d
ownload.opensuse.org/repositories/windows:/mingw:/win32/openSUSE_Leap_42.2/repod
ata/repomd.xml
INFO: Downloading https://cache.julialang.org/http://download.opensuse.org/repos
itories/windows:/mingw:/win64/openSUSE_Leap_42.2/repodata/repomd.xml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 1/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win64/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 2/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win64/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 3/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win64/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 4/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win64/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: Unknown download failure, error code: 2148270088
WARNING: Retry 5/5 downloading: https://cache.julialang.org/http://download.open
suse.org/repositories/windows:/mingw:/win64/openSUSE_Leap_42.2/repodata/repomd.x
ml
WARNING: received error 0 while downloading https://cache.julialang.org/http://d
ownload.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_Leap_42.2/repod
ata/repomd.xml
=================================[ ERROR: ZMQ ]=================================

LoadError: None of the selected providers can install dependency zmq.
Use BinDeps.debug(package_name) to see available providers

while loading C:\Users\lzhang\.julia\v0.6\ZMQ\deps\build.jl, in expression start
ing on line 35

================================================================================

INFO: Building IJulia
INFO: Installing Jupyter via the Conda package.
  File "C:\Users\lzhang\AppData\Local\Continuum\Anaconda3\lib\site.py", line 177

    file=sys.stderr)
        ^
SyntaxError: invalid syntax
===============================[ ERROR: IJulia ]================================

LoadError: Failed to find or install Jupyter 3.0 or later. Please install Jupyte
r manually, set `ENV["JUPYTER"]="/path/to/jupyter", and rerun `Pkg.build("IJulia
")`.
while loading C:\Users\lzhang\.julia\v0.6\IJulia\deps\build.jl, in expression st
arting on line 7

================================================================================

================================[ BUILD ERRORS ]================================

WARNING: IJulia and ZMQ had build errors.

 - packages with build errors remain installed in C:\Users\lzhang\.julia\v0.6
 - build the package(s) and all dependencies with `Pkg.build("IJulia", "ZMQ")`
 - build a single package by running its `deps/build.jl` script

================================================================================

One more word: I did install it by choosing "Run as administrator."

Can anyone tell me what's wrong with my installation? Thank you.

Gnimuc commented 7 years ago

Dup of #80 ? This is a common issue for Julians in mainland China.

LinZhang1004 commented 7 years ago

I am in the US, and use a laptop provided by my employer.

Gnimuc commented 7 years ago

Then that's probably a Windows firewall issue. Have you tried the solutions discussed in https://github.com/JuliaPackaging/WinRPM.jl/issues/47#issuecomment-296286392 and #90.

LinZhang1004 commented 7 years ago

I removed the prefix https://cache.julialang.org/ in the file C:\Users\lzhang\.julia\v0.6\WinRPM\sources.list. When I rerun Pkg.build("IJulia"), most errors are gone, but there is another one left.

Can you please take a look at the following new output and tell me what I should do next? Thank you!

julia> Pkg.add("IJulia")
INFO: Package IJulia is already installed

julia> Pkg.build("IJulia")
INFO: Building Conda
INFO: Building MbedTLS
INFO: Building WinRPM
WARNING: skipping repodata/repomd.xml, not in cache -- call WinRPM.update() to d
ownload
WARNING: skipping repodata/repomd.xml, not in cache -- call WinRPM.update() to d
ownload
INFO: Downloading http://download.opensuse.org/repositories/windows:/mingw:/win3
2/openSUSE_Leap_42.2/repodata/repomd.xml
INFO: Downloading http://download.opensuse.org/repositories/windows:/mingw:/win3
2/openSUSE_Leap_42.2/repodata/6c88250cc88da34102950b45d26231407850c6ea995331d433
b3c22286af0867-primary.xml.gz
INFO: Downloading http://download.opensuse.org/repositories/windows:/mingw:/win6
4/openSUSE_Leap_42.2/repodata/repomd.xml
INFO: Downloading http://download.opensuse.org/repositories/windows:/mingw:/win6
4/openSUSE_Leap_42.2/repodata/c8aa98223b4f204fb0550763277c0f593d51e46445e94906c3
85e9512ada6631-primary.xml.gz
INFO: Building ZMQ
INFO: Updating WinRPM package list
INFO: Downloading http://download.opensuse.org/repositories/windows:/mingw:/win3
2/openSUSE_Leap_42.2/repodata/repomd.xml
INFO: Downloading http://download.opensuse.org/repositories/windows:/mingw:/win6
4/openSUSE_Leap_42.2/repodata/repomd.xml
INFO: Packages to install: libwinpthread1, libstdc++6, libgcc_s_seh1, zeromq
INFO: Downloading: libwinpthread1
INFO: Extracting: libwinpthread1
INFO: Downloading: libstdc++6
INFO: Extracting: libstdc++6
INFO: Downloading: libgcc_s_seh1
INFO: Extracting: libgcc_s_seh1
INFO: Downloading: zeromq
INFO: Extracting: zeromq
INFO: Complete
INFO: Building IJulia
INFO: Installing Jupyter via the Conda package.
  File "C:\Users\lzhang\AppData\Local\Continuum\Anaconda3\lib\site.py", line 177

    file=sys.stderr)
        ^
SyntaxError: invalid syntax
===============================[ ERROR: IJulia ]================================

LoadError: Failed to find or install Jupyter 3.0 or later. Please install Jupyte
r manually, set `ENV["JUPYTER"]="/path/to/jupyter", and rerun `Pkg.build("IJulia
")`.
while loading C:\Users\lzhang\.julia\v0.6\IJulia\deps\build.jl, in expression st
arting on line 7

================================================================================

================================[ BUILD ERRORS ]================================

WARNING: IJulia had build errors.

 - packages with build errors remain installed in C:\Users\lzhang\.julia\v0.6
 - build the package(s) and all dependencies with `Pkg.build("IJulia")`
 - build a single package by running its `deps/build.jl` script

================================================================================

julia>
Gnimuc commented 7 years ago

Did you reset ENV["JUPYTER"]="" before running Pkg.build("IJulia")? Anyway, this is no longer an issue for WinRPM, you can continue the discussion here https://github.com/JuliaLang/IJulia.jl/issues/555.

LinZhang1004 commented 7 years ago

I created an issue #115 in WinRPM.jl. With the help of @Gnimuc, the ZMQ error is now gone. But when I run Pkg.build("IJulia"), there is still an error (seems a Python syntax error), as follows:

julia> Pkg.add("IJulia")
INFO: Package IJulia is already installed

julia> ENV["JUPYTER"]=""
""

julia> Pkg.build("IJulia")
INFO: Building Conda
INFO: Building MbedTLS
INFO: Building WinRPM
INFO: Downloading http://download.opensuse.org/repositories/windows:/mingw:/win3
2/openSUSE_Leap_42.2/repodata/repomd.xml
INFO: Downloading http://download.opensuse.org/repositories/windows:/mingw:/win6
4/openSUSE_Leap_42.2/repodata/repomd.xml
INFO: Building ZMQ
INFO: Updating WinRPM package list
INFO: Downloading http://download.opensuse.org/repositories/windows:/mingw:/win3
2/openSUSE_Leap_42.2/repodata/repomd.xml
INFO: Downloading http://download.opensuse.org/repositories/windows:/mingw:/win6
4/openSUSE_Leap_42.2/repodata/repomd.xml
INFO: Building IJulia
INFO: Installing Jupyter via the Conda package.
  File "C:\Users\lzhang\AppData\Local\Continuum\Anaconda3\lib\site.py", line 177

    file=sys.stderr)
        ^
SyntaxError: invalid syntax
===============================[ ERROR: IJulia ]================================

LoadError: Failed to find or install Jupyter 3.0 or later. Please install Jupyte
r manually, set `ENV["JUPYTER"]="/path/to/jupyter", and rerun `Pkg.build("IJulia
")`.
while loading C:\Users\lzhang\.julia\v0.6\IJulia\deps\build.jl, in expression st
arting on line 7

================================================================================

================================[ BUILD ERRORS ]================================

WARNING: IJulia had build errors.

 - packages with build errors remain installed in C:\Users\lzhang\.julia\v0.6
 - build the package(s) and all dependencies with `Pkg.build("IJulia")`
 - build a single package by running its `deps/build.jl` script

================================================================================

julia>

Can anyone tell me how to fix it? Thank you for your time and help!

LinZhang1004 commented 7 years ago

I got my question solved. Thank you, @Gnimuc