# Packages in the Project.toml file are not found in the project

**URL:** https://discourse.julialang.org/t/packages-in-the-project-toml-file-are-not-found-in-the-project/93494
**Category:** General Usage
**Created:** [January 25, 2023, 10:06am UTC](https://discourse.julialang.org/t/packages-in-the-project-toml-file-are-not-found-in-the-project/93494 "2023-01-25T10:06:48Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![devanshu](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/devanshu/32/37104_2.png) [@devanshu](https://discourse.julialang.org/u/devanshu)
#### Post date: [January 25, 2023, 10:06am UTC](https://discourse.julialang.org/t/packages-in-the-project-toml-file-are-not-found-in-the-project/93494/1 "2023-01-25T10:06:48Z")

</div>

Hi,

I have a project named `HeisenbergMBL`. While `precompiling` in the project environment I get the following error,

```julia
(HeisenbergMBL) pkg> precompile
Precompiling project...
  ✗ HeisenbergMBL
  0 dependencies successfully precompiled in 3 seconds. 97 already precompiled.

ERROR: The following 1 direct dependency failed to precompile:

HeisenbergMBL [82fe544b-97fe-470f-a1f1-c6b91cdd1d85]

Failed to precompile HeisenbergMBL [82fe544b-97fe-470f-a1f1-c6b91cdd1d85] to /home/20ph92r03/.julia/compiled/v1.8/HeisenbergMBL/jl_xUY0wd.
ERROR: LoadError: ArgumentError: Package Base does not have DelimitedFiles in its dependencies:
- You may have a partially installed environment. Try `Pkg.instantiate()`
  to ensure all packages in the environment are installed.
- Or, if you have Base checked out for development and have
  added DelimitedFiles as a dependency but haven't updated your primary
  environment's manifest file, try `Pkg.resolve()`.
- Otherwise you may need to report an issue with Base
Stacktrace:
 [1] macro expansion
   @ ./loading.jl:1167 [inlined]
 [2] macro expansion
   @ ./lock.jl:223 [inlined]
 [3] require(into::Module, mod::Symbol)
   @ Base ./loading.jl:1144
 [4] include
   @ ./Base.jl:419 [inlined]
 [5] 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
 [6] top-level scope
   @ stdin:1
in expression starting at /scratch/20ph92r03/juliafiles/mpiTest/HeisenbergMBL/src/HeisenbergMBL.jl:3
in expression starting at stdin:1

```

But the `status` shows that I have all the libraries installed in the environment.

```julia
(HeisenbergMBL) pkg> status
Project HeisenbergMBL v0.1.0
Status `/scratch/20ph92r03/juliafiles/mpiTest/HeisenbergMBL/Project.toml`
  [31c24e10] Distributions v0.25.80
⌅ [da04e1cc] MPI v0.19.2
  [5be22e1c] PetscWrap v0.1.5
  [3c0b384b] QuantumInformation v0.4.9
  [c3679e3b] SlepcWrap v0.1.3
  [8bb1440f] DelimitedFiles
  [37e2e46d] LinearAlgebra
  [10745b16] Statistics
Info Packages marked with ⌅ have new versions available but cannot be upgraded. To see why use `status --outdated`

```

I tried `Pkg.resolve()` and `Pkg.instantiate()` but the error persists. Here is how my `Project.toml` file looks like

```julia
name = "HeisenbergMBL"
uuid = "82fe544b-97fe-470f-a1f1-c6b91cdd1d85"
authors = ["devanshu <devanshu2096@gmail.com>"]
version = "0.1.0"

[deps]
DelimitedFiles = "8bb1440f-4735-579b-a4ab-409b98df4dab"
Distributions = "31c24e10-a181-5473-b8eb-7969acd0382f"
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
MPI = "da04e1cc-30fd-572f-bb4f-1f8673147195"
PetscWrap = "5be22e1c-01b5-4697-96eb-ef9ccdc854b8"
QuantumInformation = "3c0b384b-479c-5684-b2ef-9d7a46dd931e"
SlepcWrap = "c3679e3b-785e-4ccc-b734-b7685cbb935e"
Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2"

[extras]
MPIPreferences = "3da0fdf6-3ccc-4f1b-acd9-58baa6c99267"

[preferences.MPIPreferences]
_format = "1.0"
abi = "MPICH"
binary = "system"
libmpi = "libmpi"
mpiexec = "mpiexec"

```

I am not sure what the error is.

Thanks.

---

<div class="post-metadata">

### Author: ![fredrikekre](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/fredrikekre/32/1688_2.png) [@fredrikekre](https://discourse.julialang.org/u/fredrikekre)
#### Post date: [January 25, 2023, 10:36am UTC](https://discourse.julialang.org/t/packages-in-the-project-toml-file-are-not-found-in-the-project/93494/2 "2023-01-25T10:36:30Z")

</div>

> [@devanshu](#):
>
> `ERROR: LoadError: ArgumentError: Package Base does not have DelimitedFiles in its dependencies:`

This could be because you have code outside of the `module HeisenbergMBL ... end`, see [JuliaLang/julia#45832](https://github.com/JuliaLang/julia/issues/45832).

---

<div class="post-metadata">

### Author: ![devanshu](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/devanshu/32/37104_2.png) [@devanshu](https://discourse.julialang.org/u/devanshu)
#### Post date: [January 25, 2023, 1:43pm UTC](https://discourse.julialang.org/t/packages-in-the-project-toml-file-are-not-found-in-the-project/93494/3 "2023-01-25T13:43:48Z")

</div>

Hey, Thanks!

One more thing, why do I get a `Package not found error` when I run the code setting `export JULIA_LOAD_PATH=["@","@stdlib"]`, since I want Julia to only consider the packages and versions installed in the environment.

---

<div class="post-metadata">

### Author: ![albheim](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/albheim/32/34660_2.png) [@albheim](https://discourse.julialang.org/u/albheim)
#### Post date: [January 25, 2023, 1:53pm UTC](https://discourse.julialang.org/t/packages-in-the-project-toml-file-are-not-found-in-the-project/93494/4 "2023-01-25T13:53:36Z")

</div>

I think you are expected to use colon as the separator, see the [docs](https://docs.julialang.org/en/v1/manual/environment-variables/#JULIA_LOAD_PATH). So maybe `export JULIA_LOAD_PATH="@:@stdlib"` in your case.

Check what `Base.LOAD_PATH` is after you start julia and make sure that seems correct.
