Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to load build.jl files in packages due to problem with BinDeps.debug [Windows 7, Julia 0.4.5] #228

Closed
Vector112 opened this issue Jun 27, 2016 · 9 comments

Comments

@Vector112
Copy link

Vector112 commented Jun 27, 2016

ERROR: LoadError: No download agent available; install curl, wget, or fetch. in download_cmd at C:\Users\Jonathan\.julia\v0.4\BinDeps\src\BinDeps.jl:75 [inlined code] from C:\Users\Jonathan\.julia\v0.4\BinDeps\src\BinDeps.jl:251 in lower at C:\Users\Jonathan\.julia\v0.4\BinDeps\src\BinDeps.jl:337 [inlined code] from C:\Users\Jonathan\.julia\v0.4\BinDeps\src\BinDeps.jl:251 in generate_steps at C:\Users\Jonathan\.julia\v0.4\BinDeps\src\dependencies.jl: 366 in lower at C:\Users\Jonathan\.julia\v0.4\BinDeps\src\dependencies.jl:279 in include at boot.jl:261 in include_from_node1 at loading.jl:320 in debug_context at C:\Users\Jonathan\.julia\v0.4\BinDeps\src\debug.jl:54 in debug at C:\Users\Jonathan\.julia\v0.4\BinDeps\src\debug.jl:59 in debug at C:\Users\Jonathan\.julia\v0.4\BinDeps\src\debug.jl:65 while loading C:\Users\Jonathan\.julia\v0.4\Cairo\deps\build.jl, in expression s tarting on line 251

The above error is currently the bane of my Julia experience.

I have only installed the command-line version of Julia, and shortly began to look through Ivo Balbaert's book in order to get well acquainted with the Julia language. Upon reaching the section regarding adding packages, I came across an error regarding the Cairo package:

julia> Pkg.build("Cairo") INFO: Building WinRPM INFO: Downloading https://cache.julialang.org/http://download.opensuse.org/repos itories/windows:/mingw:/win32/openSUSE_13.2/repodata/repomd.xml INFO: Downloading https://cache.julialang.org/http://download.opensuse.org/repos itories/windows:/mingw:/win64/openSUSE_13.2/repodata/repomd.xml INFO: Downloading https://cache.julialang.org/http://download.opensuse.org/repos itories/windows:/mingw:/win64/openSUSE_13.2/repodata/85dc0be89513f521ce058fdc265 3d450e6b5219fea26649d8d9a4b0249f36eef-primary.xml.gz INFO: Building Cairo
================================[ ERROR: Cairo ]================================

LoadError: No download agent available; install curl, wget, or fetch. while loading C:\Users\Jonathan\.julia\v0.4\Cairo\deps\build.jl, in expression s tarting on line 251

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

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

WARNING: Cairo had build errors.

- packages with build errors remain installed in C:\Users\Jonathan\.julia\v0.4

- build the package(s) and all dependencies withPkg.build("Cairo")`

- build a single package by running itsdeps/build.jlscript

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

A bit of Googling shortly lead me to this thread comment on the Cairo issues page, as well as this one from the WinRPM Issues page. I tried it out on my current install of Julia, but all I received was the error message at the top of this thread regarding BinDeps.debug().

After a couple of cycles of uninstalling, reinstalling Julia and the packages, then uninstalling again, I found have remained unsuccessful. Please help me get past this.

EDIT: I forgot to indicate that BinDeps.debug() isn't working with the build files:
julia> BinDeps.debug("Calculus")

INFO: Reading build script... ERROR: could not open file C:\Users\Jonathan\.julia\v0.4\Calculus\deps\build.jl in include at boot.jl:261 in include_from_node1 at loading.jl:320 in debug_context at C:\Users\Jonathan\.julia\v0.4\BinDeps\src\debug.jl:54 in debug at C:\Users\Jonathan\.julia\v0.4\BinDeps\src\debug.jl:59 in debug at C:\Users\Jonathan\.julia\v0.4\BinDeps\src\debug.jl:65

julia> BinDeps.debug("Colors")

INFO: Reading build script... ERROR: could not open file C:\Users\Jonathan\.julia\v0.4\Colors\deps\build.jl in include at boot.jl:261 in include_from_node1 at loading.jl:320 in debug_context at C:\Users\Jonathan\.julia\v0.4\BinDeps\src\debug.jl:54 in debug at C:\Users\Jonathan\.julia\v0.4\BinDeps\src\debug.jl:59 in debug at C:\Users\Jonathan\.julia\v0.4\BinDeps\src\debug.jl:65

julia> BinDeps.debug("DataStructures")

INFO: Reading build script... ERROR: could not open file C:\Users\Jonathan\.julia\v0.4\DataStructures\deps\bui ld.jl in include at boot.jl:261 in include_from_node1 at loading.jl:320 in debug_context at C:\Users\Jonathan\.julia\v0.4\BinDeps\src\debug.jl:54 in debug at C:\Users\Jonathan\.julia\v0.4\BinDeps\src\debug.jl:59 in debug at C:\Users\Jonathan\.julia\v0.4\BinDeps\src\debug.jl:65

@Vector112 Vector112 changed the title Unable to load build.jl files in packages due to problem with BinDeps.debug [Windows 7, Julia 0.45] Unable to load Cairo build file due to problem with BinDeps.debug [Windows 7, Julia 0.45] Jun 27, 2016
@Vector112 Vector112 changed the title Unable to load Cairo build file due to problem with BinDeps.debug [Windows 7, Julia 0.45] Unable to load Cairo build file due to problem with BinDeps.debug [Windows 7, Julia 0.4.5] Jun 27, 2016
@Vector112 Vector112 changed the title Unable to load Cairo build file due to problem with BinDeps.debug [Windows 7, Julia 0.4.5] Unable to load build.jl files in packages due to problem with BinDeps.debug [Windows 7, Julia 0.4.5] Jun 27, 2016
@tkelman
Copy link
Contributor

tkelman commented Jun 27, 2016

What version of Windows are you using? By default BinDeps should be using powershell on Windows now, which should be preinstalled and on the path on all moderately recent versions of Windows. Inside Julia, try running

run(`where powershell`)
run(`powershell -h`)
ENV["PATH"]

I suspect your system is configured strangely such that powershell is not on the path. Either you or some piece of software has erroneously removed it.

@tkelman
Copy link
Contributor

tkelman commented Jun 27, 2016

By the way, it would be much more helpful for the ability of searches to find this thread if you copy-paste the text content of error messages instead of adding screenshots.

@Vector112
Copy link
Author

Vector112 commented Jun 28, 2016

I'm running Windows 7.

Okay, so running the suggested commands does provide some unusual outputs.

julia> run(where powershell)

ERROR: could not spawnwhere powershell: no such file or directory (ENOENT) in _jl_spawn at process.jl:262

julia> run(powershell -h)

ERROR: could not spawnpowershell -h: no such file or directory (ENOENT) in _jl_spawn at process.jl:262

julia> ENV["PATH"]

"C:\\Users\\Jonathan\\AppData\\Local\\Julia-0.4.5\\bin;C:\\Users\\Jonathan\\AppD ata\\Local\\Julia-0.4.5\\bin\\..\\Git\\bin;C:\\Users\\Guest\\AppData\\Local\\Jul ia-0.4.5;C:\\Program Files (x86)\\CMake\\bin"

^I think that does constitute a strange configuration. How can I get around to fixing it?

@tkelman
Copy link
Contributor

tkelman commented Jun 28, 2016

so outside of Julia, in a command prompt, what does echo %PATH% say? Did you add C:\\Program Files (x86)\\CMake\\bin in your juliarc file, or outside of Julia? It looks like you overwrote your path somewhere such that C:\\Program Files (x86)\\CMake\\bin is the only thing on it (other than what Julia adds) rather than appended to the default list. Not having the default Windows entries (things like C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;%SYSTEMROOT%\System32\WindowsPowerShell\v1.0\;%localappdata%\Microsoft\WindowsApps;%USERPROFILE%\AppData\Local\Microsoft\WindowsApps; ) on your path is bound to cause trouble with more than just Julia.

@Vector112
Copy link
Author

Vector112 commented Jun 30, 2016

C:\Users\Jonathan>echo %PATH%

C:\Users\Guest\AppData\Local\Julia-0.4.5;C:\Program Files (x86)\CMake\bin

I also don't know how to respond to the second question.

@tkelman
Copy link
Contributor

tkelman commented Jun 30, 2016

Something overwrote your path rather than appending to it.

@Vector112
Copy link
Author

How can I reset it?

@Vector112
Copy link
Author

Copy-pasting the PATH values seems to have stopped the debug problem. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants