-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Building Error #4
Comments
I'd like to +1 this on Julia 1.2. During the clone/add stage I get hit with: ┌ Error: Error building |
I've been having the same issue. Were either of you able to solve the problem? |
I have not. I suspect this is because this has been orphaned since Julia v0.6, and the language has changed significantly in that span. I'm trying to work through build.jl and see if I can fix them, but easiest thing to do for the moment in order to get CoolProp functioning is to probably utilize PyCall and just call CoolProp through that. |
I think the installation instructions need to be updated to point to this repository instead of "https://github.com/vimalaad/CoolProp.jl.git" |
I will try using PyCall. I tried it earlier but I didn't have any success. Is the following the right way to use it? using PyCall When I did this, I ran into the following issue: PyError (PyImport_ImportModule The Python package CoolProp.CoolProp could not be found by pyimport. Usually this means PyCall is currently configured to use the Julia-specific Python distribution Alternatively, if you want to use a different Python distribution on your ) <class 'ModuleNotFoundError'> Stacktrace: |
Thanks, I made a pull request with that update. It worked for me what I changed that URL without issues.
Have you done a using PyCall
cp = pyimport("CoolProp.CoolProp")
state = cp.PropsSI("T","P",101325,"Q",0,"Water")
display(state) That being said, I'd try adding it directly in Julia again via the recommendation of @cstook. I forked and edited the ReadMe to reflect this and added a pull request to try to get this updated for everyone. |
I tried using the code above and received the same error message as before. Additionally, I tried installing from CoolProp/CoolProp.jl but I had an error in building! I was able to install it on my Windows about a year ago on Julia v1.1.1 without any issues. I just switched to a Mac and I can't seem to install it on Julia v1.1.1 |
I'm on a linux box, but can check a Windows machine later too. I should have mentioned this: I needed to go into ~/.julia/dev/ and remove the old CoolProp folder as that was conflicting. After I did that the As for the Python call, my gut feeling is that however you installed CoolProp in Python (either with pip or conda), Julia's PyCall is using a different environment. I presume you've also tried toying with the environment as per this link? |
Removing the old folder and trying to build the package again worked. Thank you so much for your help! |
I tryed to install CoolProp following this steps:
Julia> Pkg.clone("https://github.com/vimalaad/CoolProp.jl.git")
%with the following message:
┌ Warning: Pkg.clone is only kept for legacy CI script reasons, please use
add
└ @ Pkg.API ~/julia/usr/share/julia/stdlib/v1.1/Pkg/src/API.jl:460
Updating registry at
~/.julia/registries/General
Updating git-repo
https://github.com/JuliaRegistries/General.git
Updating git-repo
https://github.com/vimalaad/CoolProp.jl.git
[ Info: Assigning UUID e084ae63-2819-5025-826e-f8e611a84251 to CoolProp
[ Info: Path
/home/prado/.julia/dev/CoolProp
exists and looks like the correct package, using existing path instead of cloningResolving package versions...
Updating
~/.julia/environments/v1.1/Project.toml
[no changes]
Updating
~/.julia/environments/v1.1/Manifest.toml
Then I tried:
Julia> Pkg.Build("CoolProp")
%with the following message:
Building CoolProp →
~/.julia/dev/CoolProp/deps/build.log
Resolving package versions...
┌ Error: Error building
CoolProp
:│ ERROR: LoadError: ArgumentError: isdefined: too few arguments (expected 2)
│ Stacktrace:
│ [1] top-level scope at /home/prado/.julia/dev/CoolProp/deps/build.jl:6
│ [2] include at ./boot.jl:317 [inlined]
│ [3] include_relative(::Module, ::String) at ./loading.jl:1041
│ [4] include(::Module, ::String) at ./sysimg.jl:29
│ [5] include(::String) at ./client.jl:388
│ [6] top-level scope at none:0
│ in expression starting at /home/prado/.julia/dev/CoolProp/deps/build.jl:5
I also tried add CoolProp directly using Pkg:
Julia> Pkg.add("CoolProp")
%with the following message:
Resolving package versions...
Updating
~/.julia/environments/v1.1/Project.toml
[no changes]
Updating
~/.julia/environments/v1.1/Manifest.toml
Then I tried:
Julia> using CoolProp
%with the following message:
[ Info: Precompiling CoolProp [e084ae63-2819-5025-826e-f8e611a84251]
ERROR: LoadError: UndefVarError: Libdl not defined
Stacktrace:
[1] top-level scope at none:0
[2] include at ./boot.jl:317 [inlined]
[3] include_relative(::Module, ::String) at ./loading.jl:1041
[4] include(::Module, ::String) at ./sysimg.jl:29
[5] top-level scope at none:2
[6] eval at ./boot.jl:319 [inlined]
[7] eval(::Expr) at ./client.jl:389
[8] top-level scope at ./none:3
in expression starting at /home/prado/.julia/dev/CoolProp/src/CoolProp.jl:1
ERROR: Failed to precompile CoolProp [e084ae63-2819-5025-826e-f8e611a84251] to /home/prado/.julia/compiled/v1.1/CoolProp/TgXq7.ji.
Stacktrace:
[1] error(::String) at ./error.jl:33
[2] macro expansion at ./logging.jl:313 [inlined]
[3] compilecache(::Base.PkgId, ::String) at ./loading.jl:1187
[4] macro expansion at ./logging.jl:311 [inlined]
[5] _require(::Base.PkgId) at ./loading.jl:944
[6] require(::Base.PkgId) at ./loading.jl:855
[7] macro expansion at ./logging.jl:311 [inlined]
[8] require(::Module, ::Symbol) at ./loading.jl:837
The text was updated successfully, but these errors were encountered: