valentinsulzer / PyBaMM.jl

Julia bindings for PyBaMM
MIT License
13 stars 1 forks source link

Wrong installation #36

Open DarioSlaifsteinSk opened 1 year ago

DarioSlaifsteinSk commented 1 year ago

Hi! When doing:

using PyBaMM

I get this stacktrace error:

[ Info: Precompiling PyBaMM [fca5ce96-07e6-488e-83f1-b08868dda0ac]
    CondaPkg Found dependencies: C:\Users\dslaifstein\.julia\packages\PythonCall\3GRYN\CondaPkg.toml
    CondaPkg Found dependencies: C:\Users\dslaifstein\.julia\packages\PyBaMM\kCs3d\CondaPkg.toml
    CondaPkg Resolving changes
             + pip
             + pybamm (pip)
             + python
    CondaPkg Removing environment
             │ C:\Users\dslaifstein\.julia\artifacts\ef950c8221e5f085ba22017eadffe335d218bc2d\bin\micromamba.exe
             │ -r C:\Users\dslaifstein\.julia\scratchspaces\0b3b1443-0f03-428d-bdfb-f27f9c1191ea\root
             │ remove
             │ -y
             │ -p C:\Users\dslaifstein\.julia\environments\v1.8\.CondaPkg\env
             └ --all

                                           __
          __  ______ ___  ____ _____ ___  / /_  ____ _
         / / / / __ `__ \/ __ `/ __ `__ \/ __ \/ __ `/
        / /_/ / / / / / / /_/ / / / / / / /_/ / /_/ /
       / .___/_/ /_/ /_/\__,_/_/ /_/ /_/_.___/\__,_/
      /_/

Transaction

  Prefix: C:\Users\dslaifstein\.julia\environments\v1.8\.CondaPkg\env

  Removing specs:

   - bzip2
   - ca-certificates
   - libffi
   - libsqlite
   - libzlib
   - openssl
   - pip
   - python
   - setuptools
   - tk
   - tzdata
   - ucrt
   - vc
   - vs2015_runtime
   - wheel
   - xz

  Package                 Version  Build               Channel           Size
-------------------------------------------------------------------------------
  Remove:
-------------------------------------------------------------------------------

  - bzip2                   1.0.8  h8ffe710_4          conda-forge     Cached
  - ca-certificates     2022.12.7  h5b45459_0          conda-forge     Cached
  - libffi                  3.4.2  h8ffe710_5          conda-forge     Cached
  - libsqlite              3.40.0  hcfcfb64_0          conda-forge     Cached
  - libzlib                1.2.13  hcfcfb64_4          conda-forge     Cached
  - openssl                 3.0.8  hcfcfb64_0          conda-forge     Cached
  - pip                      23.0  pyhd8ed1ab_0        conda-forge     Cached
  - python                 3.9.16  h4de0772_0_cpython  conda-forge     Cached
  - setuptools             67.3.2  pyhd8ed1ab_0        conda-forge     Cached
  - tk                     8.6.12  h8ffe710_0          conda-forge     Cached
  - tzdata                  2022g  h191b570_0          conda-forge     Cached
  - ucrt             10.0.22621.0  h57928b3_0          conda-forge     Cached
  - vc                       14.3  hb6edc58_10         conda-forge     Cached
  - vs2015_runtime    14.34.31931  h4c5c07a_10         conda-forge     Cached
  - wheel                  0.38.4  pyhd8ed1ab_0        conda-forge     Cached
  - xz                      5.2.6  h8d14728_0          conda-forge     Cached

  Summary:

  Remove: 16 packages

  Total download: 0 B

-------------------------------------------------------------------------------

Transaction starting
Unlinking pip-23.0-pyhd8ed1ab_0
Unlinking python-3.9.16-h4de0772_0_cpython
Unlinking setuptools-67.3.2-pyhd8ed1ab_0
Unlinking wheel-0.38.4-pyhd8ed1ab_0
Unlinking xz-5.2.6-h8d14728_0
Unlinking tzdata-2022g-h191b570_0
Unlinking tk-8.6.12-h8ffe710_0
Unlinking openssl-3.0.8-hcfcfb64_0
Unlinking libzlib-1.2.13-hcfcfb64_4
Unlinking libsqlite-3.40.0-hcfcfb64_0
Unlinking libffi-3.4.2-h8ffe710_5
Unlinking bzip2-1.0.8-h8ffe710_4
Unlinking ca-certificates-2022.12.7-h5b45459_0
Unlinking vc-14.3-hb6edc58_10
Unlinking vs2015_runtime-14.34.31931-h4c5c07a_10
Unlinking ucrt-10.0.22621.0-h57928b3_0
Transaction finished
    CondaPkg Creating environment
             │ C:\Users\dslaifstein\.julia\artifacts\ef950c8221e5f085ba22017eadffe335d218bc2d\bin\micromamba.exe
             │ -r C:\Users\dslaifstein\.julia\scratchspaces\0b3b1443-0f03-428d-bdfb-f27f9c1191ea\root
             │ create
             │ -y
             │ -p C:\Users\dslaifstein\.julia\environments\v1.8\.CondaPkg\env
             │ --override-channels
             │ --no-channel-priority
             │ pip[version='>=22.0.0']
             │ python[version='>=3.7,<4',channel='conda-forge',build='*cpython*']
             │ python[version='=3.9']
             └ -c conda-forge

                                           __
          __  ______ ___  ____ _____ ___  / /_  ____ _
         / / / / __ `__ \/ __ `/ __ `__ \/ __ \/ __ `/
        / /_/ / / / / / / /_/ / / / / / / /_/ / /_/ /
       / .___/_/ /_/ /_/\__,_/_/ /_/ /_/_.___/\__,_/
      /_/

conda-forge/win-64                                          Using cache
conda-forge/noarch                                          Using cache

Transaction

  Prefix: C:\Users\dslaifstein\.julia\environments\v1.8\.CondaPkg\env

  Updating specs:

   - pip[version='>=22.0.0']
   - conda-forge::python[version='>=3.7,<4',build=*cpython*]
   - python===3.9

  Package                 Version  Build               Channel                  Size
--------------------------------------------------------------------------------------
  Install:
--------------------------------------------------------------------------------------

  + bzip2                   1.0.8  h8ffe710_4          conda-forge/win-64     Cached
  + ca-certificates     2022.12.7  h5b45459_0          conda-forge/win-64     Cached
  + libffi                  3.4.2  h8ffe710_5          conda-forge/win-64     Cached
  + libsqlite              3.40.0  hcfcfb64_0          conda-forge/win-64     Cached
  + libzlib                1.2.13  hcfcfb64_4          conda-forge/win-64     Cached
  + openssl                 3.0.8  hcfcfb64_0          conda-forge/win-64     Cached
  + pip                      23.0  pyhd8ed1ab_0        conda-forge/noarch     Cached
  + python                 3.9.16  h4de0772_0_cpython  conda-forge/win-64     Cached
  + setuptools             67.3.2  pyhd8ed1ab_0        conda-forge/noarch     Cached
  + tk                     8.6.12  h8ffe710_0          conda-forge/win-64     Cached
  + tzdata                  2022g  h191b570_0          conda-forge/noarch     Cached
  + ucrt             10.0.22621.0  h57928b3_0          conda-forge/win-64     Cached
  + vc                       14.3  hb6edc58_10         conda-forge/win-64     Cached
  + vs2015_runtime    14.34.31931  h4c5c07a_10         conda-forge/win-64     Cached
  + wheel                  0.38.4  pyhd8ed1ab_0        conda-forge/noarch     Cached
  + xz                      5.2.6  h8d14728_0          conda-forge/win-64     Cached

  Summary:

  Install: 16 packages

  Total download: 0 B

--------------------------------------------------------------------------------------

Transaction starting
Linking tzdata-2022g-h191b570_0
Linking ca-certificates-2022.12.7-h5b45459_0
Linking ucrt-10.0.22621.0-h57928b3_0
Linking vs2015_runtime-14.34.31931-h4c5c07a_10
Linking vc-14.3-hb6edc58_10
Linking openssl-3.0.8-hcfcfb64_0
Linking libffi-3.4.2-h8ffe710_5
Linking bzip2-1.0.8-h8ffe710_4
Linking xz-5.2.6-h8d14728_0
Linking tk-8.6.12-h8ffe710_0
Linking libzlib-1.2.13-hcfcfb64_4
Linking libsqlite-3.40.0-hcfcfb64_0
Linking python-3.9.16-h4de0772_0_cpython
Linking wheel-0.38.4-pyhd8ed1ab_0
Linking setuptools-67.3.2-pyhd8ed1ab_0
Linking pip-23.0-pyhd8ed1ab_0
Transaction finished
    CondaPkg Installing Pip packages
             │ C:\Users\dslaifstein\.julia\environments\v1.8\.CondaPkg\env\Scripts\pip.exe
             │ install
             └ pybamm @ git+https://github.com/abillscmu/PyBaMM@nonallocating-noncacheing
Collecting pybamm@ git+https://github.com/abillscmu/PyBaMM@nonallocating-noncacheing
  Cloning https://github.com/abillscmu/PyBaMM (to revision nonallocating-noncacheing) to c:\users\dslaifstein\appdata\local\temp\pip-install-azg33r_v\pybamm_00a0203173d54e4cbae75a7f9707cd47
  Running command git clone --filter=blob:none --quiet https://github.com/abillscmu/PyBaMM 'C:\Users\dslaifstein\AppData\Local\Temp\pip-install-azg33r_v\pybamm_00a0203173d54e4cbae75a7f9707cd47'
  error: unable to create file pybamm/input/parameters/lithium_ion/testing_only/electrolytes/lipf6_EMC_FEC_19_1_Landesfeind2019/electrolyte_transference_number_EMC_FEC_19_1_Landesfeind2019.py: Filename too long
  fatal: unable to checkout working tree
  warning: Clone succeeded, but checkout failed.
  You can inspect what was checked out with 'git status'
  and retry with 'git restore --source=HEAD :/'

  error: subprocess-exited-with-error

  × git clone --filter=blob:none --quiet https://github.com/abillscmu/PyBaMM 'C:\Users\dslaifstein\AppData\Local\Temp\pip-install-azg33r_v\pybamm_00a0203173d54e4cbae75a7f9707cd47' did not run successfully.
  │ exit code: 128
  ╰─> See above for output.

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× git clone --filter=blob:none --quiet https://github.com/abillscmu/PyBaMM 'C:\Users\dslaifstein\AppData\Local\Temp\pip-install-azg33r_v\pybamm_00a0203173d54e4cbae75a7f9707cd47' did not run successfully.
│ exit code: 128
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: LoadError: InitError: failed process: Process(`'C:\Users\dslaifstein\.julia\environments\v1.8\.CondaPkg\env\Scripts\pip.exe' install 'pybamm @ git+https://github.com/abillscmu/PyBaMM@nonallocating-noncacheing'`, ProcessExited(1)) [1]

Stacktrace:
  [1] pipeline_error
    @ .\process.jl:565 [inlined]
  [2] run(::Cmd; wait::Bool)
    @ Base .\process.jl:480
  [3] run(::Cmd)
    @ Base .\process.jl:477
  [4] _run(io::IO, cmd::Cmd, args::Any; flags::Any)
    @ CondaPkg C:\Users\dslaifstein\.julia\packages\CondaPkg\j2Cct\src\resolve.jl:370
  [5] (::CondaPkg.var"#29#30"{Base.TTY, Vector{String}, Vector{String}, Vector{String}})()
    @ CondaPkg C:\Users\dslaifstein\.julia\packages\CondaPkg\j2Cct\src\resolve.jl:304
  [6] withenv(f::Function)
    @ CondaPkg C:\Users\dslaifstein\.julia\packages\CondaPkg\j2Cct\src\env.jl:44
  [7] _resolve_pip_install(io::Any, pip_specs::Any, load_path::Any)
    @ CondaPkg C:\Users\dslaifstein\.julia\packages\CondaPkg\j2Cct\src\resolve.jl:301
  [8] resolve(; force::Bool, io::IO, interactive::Bool, dry_run::Bool)
    @ CondaPkg C:\Users\dslaifstein\.julia\packages\CondaPkg\j2Cct\src\resolve.jl:529
  [9] resolve()
    @ CondaPkg C:\Users\dslaifstein\.julia\packages\CondaPkg\j2Cct\src\resolve.jl:384
 [10] envdir()
    @ CondaPkg C:\Users\dslaifstein\.julia\packages\CondaPkg\j2Cct\src\env.jl:70
 [11] init_context()
    @ PythonCall.C C:\Users\dslaifstein\.julia\packages\PythonCall\3GRYN\src\cpython\context.jl:63
 [12] __init__()
    @ PythonCall.C C:\Users\dslaifstein\.julia\packages\PythonCall\3GRYN\src\cpython\CPython.jl:21
 [13] _include_from_serialized(pkg::Base.PkgId, path::String, depmods::Vector{Any})
    @ Base .\loading.jl:831
 [14] _require_search_from_serialized(pkg::Base.PkgId, sourcepath::String, build_id::UInt64)
    @ Base .\loading.jl:1039
 [15] _require(pkg::Base.PkgId)
    @ Base .\loading.jl:1315
 [16] _require_prelocked(uuidkey::Base.PkgId)
    @ Base .\loading.jl:1200
 [17] macro expansion
    @ .\loading.jl:1180 [inlined]
 [18] macro expansion
    @ .\lock.jl:223 [inlined]
 [19] require(into::Module, mod::Symbol)
    @ Base .\loading.jl:1144
 [20] include
    @ .\Base.jl:419 [inlined]
 [21] include_package_for_output(pkg::Base.PkgId, input::String, depot_path::Vector{String}, dl_load_path::Vector{String}, load_path::Vector{String}, concrete_deps::Vector{Pair{Base.PkgId, UInt64}}, source::Nothing)
    @ Base .\loading.jl:1554
 [22] top-level scope
    @ stdin:1
during initialization of module C
in expression starting at C:\Users\dslaifstein\.julia\packages\PyBaMM\kCs3d\src\PyBaMM.jl:1
in expression starting at stdin:1
ERROR: Failed to precompile PyBaMM [fca5ce96-07e6-488e-83f1-b08868dda0ac] to C:\Users\dslaifstein\.julia\compiled\v1.8\PyBaMM\jl_D812.tmp.
Stacktrace:
 [1] error(s::String)
   @ Base .\error.jl:35
 [2] compilecache(pkg::Base.PkgId, path::String, internal_stderr::IO, internal_stdout::IO, keep_loaded_modules::Bool)
   @ Base .\loading.jl:1707
 [3] compilecache
   @ .\loading.jl:1651 [inlined]
 [4] _require(pkg::Base.PkgId)
   @ Base .\loading.jl:1337
 [5] _require_prelocked(uuidkey::Base.PkgId)
   @ Base .\loading.jl:1200
 [6] macro expansion
   @ .\loading.jl:1180 [inlined]
 [7] macro expansion
   @ .\lock.jl:223 [inlined]
 [8] require(into::Module, mod::Symbol)
   @ Base .\loading.jl:1144

The package seems to be correctly installed, cause doing:

] status PyBaMM

returns

Status `C:\Users\dslaifstein\.julia\environments\v1.8\Project.toml`
  [fca5ce96] PyBaMM v0.1.0 `https://github.com/tinosulzer/PyBaMM.jl#main`

So, what is the problem? My version of julia is 1.8.5 (2023-01-08)

valentinsulzer commented 1 year ago

I am no longer maintaining this repository, sorry