Building error with IJulia - julia

I used to use Julia in Jupyter notebook. I uninstalled yesterday the .julia directory because of other issues and after Pkg.add(IJulia) Im getting a building error related to ZMQ. the full error is below.
julia> Pkg.build("ZMQ")
INFO: Building Homebrew
Already up-to-date.
INFO: Building ZMQ
Warning: staticfloat/juliatranslated/zeromq32-3.2.5 already installed, it's just not linked.
Error: Formulae found in multiple taps:
* staticfloat/juliadeps/zeromq32
* staticfloat/juliatranslated/zeromq32
Please use the fully-qualified name e.g. staticfloat/juliadeps/zeromq32 to refer the formula.
=================================[ ERROR: ZMQ ]=================================
LoadError: failed process: Process(`/Users/pacagal/.julia/v0.5/Homebrew/deps/usr/bin/brew link staticfloat/juliatranslated/zeromq32 --force`, ProcessExited(1)) [1]
while loading /Users/pacagal/.julia/v0.5/ZMQ/deps/build.jl, in expression starting on line 35
================================================================================
================================[ BUILD ERRORS ]================================
WARNING: ZMQ had build errors.
- packages with build errors remain installed in /Users/pacagal/.julia/v0.5
- build the package(s) and all dependencies with `Pkg.build("ZMQ")`
- build a single package by running its `deps/build.jl` script
================================================================================
I have also run the build.jl file but I am getting an error too.

I was having the same issue this morning. In the terminal I ran brew install zmq and that resolved the issue.
I still had to run julia>Pkg.build("Nettle") after installing zmq and after that IJulia is running fine.

Related

ERROR conda.core.link:_execute(700): An error occurred while installing package 'conda-forge::jupyter_nbextensions_configurator-0.4.1-py37_0'

I'm trying to install jupyter_nbextensions_configurator on windows10 for python3.7 using conda.
An error occurred while installing the package.
I have already tried to reinstall anaconda,but the problem still occurs.
ERROR conda.core.link:_execute(700): An error occurred while installing package 'conda-forge::jupyter_nbextensions_configurator-0.4.1-py37_0'.
Rolling back transaction: done
LinkError: post-link script failed for package conda-forge::jupyter_nbextensions_configurator-0.4.1-py37_0
location of failed script: C:\Users\Cesare\Anaconda3\Scripts\.jupyter_nbextensions_configurator-post-link.bat
I want to know how to install it successfully.
I too was facing the same problem. Here's the output when I tried cloning the base environment [Running as Administrator]:
(base) PS C:\WINDOWS\system32> conda create --name django --clone base
WARNING: A conda environment already exists at 'C:\Users\Tanishk\anaconda3\envs\django'
Remove existing environment (y/[n])? y
Source: C:\Users\Tanishk\anaconda3
Destination: C:\Users\Tanishk\anaconda3\envs\django
The following packages cannot be cloned out of the root environment:
- conda-forge/win-64::conda-4.9.2-py38haa244fe_0
- defaults/win-64::conda-build-3.20.5-py38_1
- defaults/win-64::conda-env-2.6.0-1
Packages: 305
Files: 2077
Preparing transaction: done
Executing transaction: done
ERROR conda.core.link:_execute(698): An error occurred while installing package 'defaults::openssl-1.1.1h-he774522_0'.
Rolling back transaction: done
CondaError: Cannot link a source that does not exist. C:\Users\Tanishk\anaconda3\pkgs\openssl-1.1.1h-he774522_0\Library\bin\openssl.exe
Running `conda clean --packages` may resolve your problem.
()
You will notice the package giving me problem is different than yours, but the ERROR remains the same (ERROR conda.core.link).
Here's how I solved it:
Google the package mentioned in the ERROR. In my case it was openssl-1.1.1h-he774522_0
Open the result from Anaconda Files (should likely be the first search result):
anaconda / packages / openssl 1 - Files :: Anaconda Cloud
Ctrl+F to find the package in the list.
Download the compressed package to your local Downloads folder.
Backup the contents of the installed erroneous package *C:\Users\Tanishk\anaconda3\pkgs\openssl-1.1.1h-he774522_0* somewhere.
Copy the contents of the de-compressed downloaded package into the *C:\Users\Tanishk\anaconda3\pkgs\openssl-1.1.1h-he774522_0* folder.
Re-try in Anaconda prompt with whatever you got stuck at.
Note:
After step 7, I got another same error but for a different package this time (vs2015_runtime-14.16.27012-hf0eaf9b_3). I performed the same steps for this package too --> Google -- Download -- Replace old content. And I was able to run things successfully after that.
I suggest to google the package because if you search for the package name on Anaconda itself, it will ask you to login first.

Fail to install RCall - Julia package

Following RCall's documentation, I ran Pkg.add("RCall") which looked to be working. Then, running using RCall gave:
WARNING: could not import StatsModels.Formula into RCall
ERROR: LoadError: RCall not properly installed. Please run Pkg.build("RCall")
#... few lines later
ERROR: Failed to precompile RCall [6f49c342-dc21-5d91-9882-a32aef131414] to C:\Users\jke4\.julia\compiled\v1.1\RCall\8GFyb.ji.
That's why I ran Pkg.build("RCall"):
┌ Error: Error building `RCall`:
│ ERROR: LoadError: R cannot be found. Set the "R_HOME" environment variable to re-run Pkg.build("RCall").
I believe, accordingly to RCall's documentation that I have to do a custom installation, but why can't am I able to simply install by Pkg.add("RCall") like it's suppose to be done?
RCall.jl can simply be installed with
Pkg.add("RCall")
Note:
Julia version is 1.1.0.
using Conda does work.
There is no R version installed in my Windows computer
I do understand what is my error message and how I can deal with it. My question is why do I have it whereas I wasn't suppose to, quoting RCall's documentation:
RCall.jl will automatically install R for you using Conda if it doesn't detect that you have R 3.4.0 or later installed already.
Update
Alright, I've done what #Cameron Bieganek suggests: pkg> pin StatsModels#0.5
And it seems to work for a moment. However, after doing ] up, accordingly with the issue I had in this question.
using RCall now gives:
ERROR: LoadError: RCall not properly installed. Please run Pkg.build("RCall")
and Pkg.build("RCall"):
┌ Error: Error building `RCall`:
│ ERROR: LoadError: IOError: stat: invalid argument (EINVAL)
This time I can't get what's the error.
GitHub
Please note that this question is also referenced on GitHub RCall.jl.

ENOENT while using R pkgdown

Cloning the v 1.1.0 of pkgdown and trying to run pkgdown::build_site() gives me the following error:
> pkgdown::build_site()
══ Building pkgdown site ═══════════════════════════════════════════════════════
Reading from: '/home/farm/Documents/pkgdown-1.1.0'
Writing to: '/home/farm/Documents/pkgdown-1.1.0/docs'
── Initialising site ───────────────────────────────────────────────────────────
Writing 'sitemap.xml'
── Building home ───────────────────────────────────────────────────────────────
<ENOENT: [ENOENT] Failed to remove '/tmp/Rtmp0utBMA/file114d619b1b68.html': no such file or directory>
Error: [ENOENT] Failed to remove '/tmp/Rtmp0utBMA/file114d619b1b68.html': no such file or directory
Execution halted
Most likely is a problem with my Linux and R, not the package itself. That being said, this is the environment:
R: 3.5.1
Manjaro: 18.0.0-rc
How can I fix this? I'm trying to avoid using chmod -R 777 /tmp/
note: I also ran devtools::test() and devtools::check(), no errors or warnings.
After trying to build a package from scratch, I found my mistake... Pandoc was missing, installing it from AUR fixed it.

Setting up IJulia

I am trying to set up IJulia on my PC, but after I get it running I get the constant messages that "kernel has died" and there is a problem with ZMQ library.
Trying to rebuild or reinstall ZMQ does not work. I get an error:
================================[ BUILD ERRORS ]================================
WARNING: ZMQ had build errors.
- packages with build errors remain installed in C:\Users\Gisaev\.julia\v0.3
- build the package(s) and all dependencies with `Pkg.build("ZMQ")`
- build a single package by running its `deps/build.jl` script
Trying to execute build.jl by line (part that correspond to windows) I get the error "Provider PackageManager faild to satisfy dependency zmq."
I am kind of lost here, because ZMQ is obviously correctly installed and working for IPython - IPython notebooks work just fine; I have a fresh installation from Anaconda.
Try to run
Pkg.build("ZMQ")
to see what happens.
If there are warnings about "libpgm" and "zeromq32", you can delete the lib directories and then try to build ZMQ again.
rm -rf /Users/username/.julia/v0.x/Homebrew/deps/usr/Cellar/zeromq32/3.2.5
rm -rf /Users/username/.julia/v0.x/Homebrew/deps/usr/Cellar/libpgm/5.2.122
Pkg.build("ZMQ")
This will correctly build the libpgm and zeromq32 you needed.
(I suppose the operation system is OS X. If you are using Windows, please refer to Installing ZMQ on Windows 7+ seems to require admin privileges #69.)

Installing Cairo and Winston for Julia

I am trying to install the Cairo and Winston packages fro Julia.
However, this is the following output that I receive when I try to test Winston.
julia> Pkg.add("Winston")
INFO: Nothing to be done.
julia> using Winston
ERROR: could not open file /Users/sethhirsh/.julia/v0.2/Cairo/src/../deps/deps.jl
in include at boot.jl:238
in include_from_node1 at loading.jl:114
in include at boot.jl:238
in include_from_node1 at loading.jl:114
in reload_path at loading.jl:140
in _require at loading.jl:58
in require at loading.jl:46
vin include at boot.jl:238
in include_from_node1 at loading.jl:114
in reload_path at loading.jl:140
in _require at loading.jl:58
in require at loading.jl:46
at /Users/sethhirsh/.julia/v0.2/Cairo/src/Cairo.jl:3
at /Users/sethhirsh/.julia/v0.2/Winston/src/Winston.jl:3
julia> Pkg.add("Cairo")
INFO: Nothing to be done.
================================[ ERROR: Cairo ]================================
failed process: Process(/Users/sethhirsh/.julia/v0.2/Cairo/deps/src/glib-2.34.3/configure --prefix=/Users/sethhirsh/.julia/v0.2/Cairo/deps/usr, ProcessExited(1)) [1]v
at /Users/sethhirsh/.julia/v0.2/Cairo/deps/build.jl:130`
================================================================================
================================[ BUILD ERRORS ]================================
WARNING: Homebrew and Cairo had build errors.
packages with build errors remain installed in /Users/sethhirsh/.julia/v0.2
build a package and all its dependencies with `Pkg.build(pkg)
build a single package by running its deps/build.jl script
================================================================================ `
Any help in fixing these errors is appreciated.
Me too got these errors once. For me When adding 'Winston' library 'Cairo' was a dependency. So What I would suggest is to completely uninstall Julia from system, because Package.rm() may not not make things clear for re-installation of packages alone. Then reinstall the Julia and make sure internet connection before typing Package.add("Winston"). Cairo will come along.

Resources