# How to solve problem with TOML.jl?

**URL:** <https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319>\
**Category:** General Usage\
**Created:** [February 25, 2018, 6:01pm UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319 "2018-02-25T18:01:28Z")\
**Posts on this page:** 20\
**Page:** 2

<div class="post-metadata">

**Author:** ![chakravala](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/chakravala/32/6832_2.png) [@chakravala](https://discourse.julialang.org/u/chakravala)\
**Post date:** [August 13, 2018, 5:18pm UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/21 "2018-08-13T17:18:51Z")

</div>

In my application, that is not required yet, but I agree that it should be backported once that is fixed.

---

<div class="post-metadata">

**Author:** ![wildart](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/wildart/32/57_2.png) [@wildart](https://discourse.julialang.org/u/wildart)\
**Post date:** [August 13, 2018, 7:11pm UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/22 "2018-08-13T19:11:12Z")

</div>

I updated [TOML.jl](https://github.com/wildart/TOML.jl) to support Julia v1.0.

You can install it from package manager REPL as follows:

```julia
(v1.0) pkg> add https://github.com/wildart/TOML.jl.git#v0.4.0

```

---

<div class="post-metadata">

**Author:** ![tobias.knopp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tobias.knopp/32/7551_2.png) [@tobias.knopp](https://discourse.julialang.org/u/tobias.knopp)\
**Post date:** [August 13, 2018, 7:59pm UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/23 "2018-08-13T19:59:18Z")

</div>

Awesome, thanks so much! Could you also register the package such that we can use it in our REQUIRE files? That would be great.

---

<div class="post-metadata">

**Author:** ![kristoffer.carlsson](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kristoffer.carlsson/32/22_2.png) [@kristoffer.carlsson](https://discourse.julialang.org/u/kristoffer.carlsson)\
**Post date:** [August 13, 2018, 8:13pm UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/24 "2018-08-13T20:13:51Z")

</div>

There is another TOML.jl package occupying that spot in METADATA so it either needs to change name or wait until we swap over to the other registry which can handle multiple packages with the same name.

---

<div class="post-metadata">

**Author:** ![tobias.knopp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tobias.knopp/32/7551_2.png) [@tobias.knopp](https://discourse.julialang.org/u/tobias.knopp)\
**Post date:** [August 13, 2018, 8:25pm UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/25 "2018-08-13T20:25:10Z")

</div>

That package seems to be abandoned since its REQUIRE contains julia 0.3. Maybe its author is fine with replacing the it with the more recent, just ported package. But probably one should first think about moving the wildart package to JuliaIO if @wildart is fine with that. Then its kind of clear that that will be the home for the one an only future TOML package.

---

<div class="post-metadata">

**Author:** ![chakravala](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/chakravala/32/6832_2.png) [@chakravala](https://discourse.julialang.org/u/chakravala)\
**Post date:** [August 13, 2018, 10:31pm UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/26 "2018-08-13T22:31:17Z")

</div>

> [@wildart](#):
>
> I updated [TOML.jl](https://github.com/wildart/TOML.jl) to support Julia v1.0.

Does it also have the same modifications as the one in `Pkg` has?

---

<div class="post-metadata">

**Author:** ![tobias.knopp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tobias.knopp/32/7551_2.png) [@tobias.knopp](https://discourse.julialang.org/u/tobias.knopp)\
**Post date:** [August 20, 2018, 11:12am UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/27 "2018-08-20T11:12:55Z")

</div>

@kristoffer.carlsson: This now gets really tricky. I want to use the wildart TOML and did:

```julia
 pkg> add https://github.com/wildart/TOML.jl.git#v0.4.0

```

Then within my Project I had to add TOML into the REQUIRE file since it is a dependency. When I then clone my project it will not use the wildart one but the one that is in METADATA:

```julia
julia> using MPIUI
[Info: Precompiling MPIUI [2d18b7e9-d7cf-55e5-b337-253b287f28b1]
\u250c Warning: Deprecated syntax `type` at /home/knopp/.julia/packages/TOML/FjcHF/src/TOML.jl:18.
\u2502 Use `mutable struct` instead.
\u2514 @ ~/.julia/packages/TOML/FjcHF/src/TOML.jl:18
ERROR: LoadError: syntax: invalid escape sequence

```

How can this be resolved?

---

<div class="post-metadata">

**Author:** ![kristoffer.carlsson](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kristoffer.carlsson/32/22_2.png) [@kristoffer.carlsson](https://discourse.julialang.org/u/kristoffer.carlsson)\
**Post date:** [August 20, 2018, 11:46am UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/28 "2018-08-20T11:46:21Z")

</div>

Packages cannot depend on unregistered packages (at least not in the sense that they can just be `pkg add`ed), right now.

If you have an “application” (a package that you are setting as your active environment, and will not be depended on by other packages) then you can store whatever you want in there since everything is stored in the Manifest.

---

<div class="post-metadata">

**Author:** ![tobias.knopp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tobias.knopp/32/7551_2.png) [@tobias.knopp](https://discourse.julialang.org/u/tobias.knopp)\
**Post date:** [August 20, 2018, 11:49am UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/29 "2018-08-20T11:49:53Z")

</div>

Yes but the advice in another thread was to put the depending package into the REQUIRE file. Here the particular issue now is that there is a package in METADATA that is old and deprecated. Without that, it would work, if a clone the unregistered packages upfront.

---

<div class="post-metadata">

**Author:** ![tobias.knopp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tobias.knopp/32/7551_2.png) [@tobias.knopp](https://discourse.julialang.org/u/tobias.knopp)\
**Post date:** [August 20, 2018, 11:50am UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/30 "2018-08-20T11:50:28Z")

</div>

A hack is to remove TOML from

```julia
~/.julia/registries/General/Registry.toml

```

but this really is a hack.

---

<div class="post-metadata">

**Author:** ![kristoffer.carlsson](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kristoffer.carlsson/32/22_2.png) [@kristoffer.carlsson](https://discourse.julialang.org/u/kristoffer.carlsson)\
**Post date:** [August 20, 2018, 11:57am UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/31 "2018-08-20T11:57:48Z")

</div>

Yes, the problem with REQUIRE files is that they cannot differentiate between two packages with the same name. With project files, these packages would have different UUIDs so we would know what “TOML” we are talking about.

---

<div class="post-metadata">

**Author:** ![tobias.knopp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tobias.knopp/32/7551_2.png) [@tobias.knopp](https://discourse.julialang.org/u/tobias.knopp)\
**Post date:** [August 20, 2018, 12:00pm UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/32 "2018-08-20T12:00:49Z")

</div>

Hm, we need a workaround for this because it makes depending on the TOML package impossible. Is there really no way that we switch the url in METADATA? I thought this has happened in the past when a package moved.

---

<div class="post-metadata">

**Author:** ![JeffreySarnoff](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jeffreysarnoff/32/1980_2.png) [@JeffreySarnoff](https://discourse.julialang.org/u/JeffreySarnoff)\
**Post date:** [August 20, 2018, 2:28pm UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/33 "2018-08-20T14:28:40Z")

</div>

The Community encourages an admin to replace the METADATA that attaches very old and very unsupported and very unresponsive current claimant to `TOML.jl` with wildart’s.

---

<div class="post-metadata">

**Author:** ![tobias.knopp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tobias.knopp/32/7551_2.png) [@tobias.knopp](https://discourse.julialang.org/u/tobias.knopp)\
**Post date:** [August 20, 2018, 2:34pm UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/34 "2018-08-20T14:34:25Z")

</div>

@JeffreySarnoff: Thanks, I supposed that thats the way how this works. Do you know who is the one to be pinged here. As I have said above: Potentially it would be better to first move `TOML.jl` to JuliaIO which gives it the blessing that this will be the one and only TOML package in the future. That would (kindof) also justify dropping the old TOML (that does not work and Julia 0.6+).

---

<div class="post-metadata">

**Author:** ![JeffreySarnoff](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jeffreysarnoff/32/1980_2.png) [@JeffreySarnoff](https://discourse.julialang.org/u/JeffreySarnoff)\
**Post date:** [August 20, 2018, 2:58pm UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/35 "2018-08-20T14:58:09Z")

</div>

@StefanKarpinski is the shot-caller on this.

---

<div class="post-metadata">

**Author:** ![StefanKarpinski](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/stefankarpinski/32/24_2.png) [@StefanKarpinski](https://discourse.julialang.org/u/StefanKarpinski)\
**Post date:** [August 20, 2018, 3:00pm UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/36 "2018-08-20T15:00:18Z")

</div>

We’ll deal with it once we’ve switched over to the new General registry.

---

<div class="post-metadata">

**Author:** ![tobias.knopp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tobias.knopp/32/7551_2.png) [@tobias.knopp](https://discourse.julialang.org/u/tobias.knopp)\
**Post date:** [August 20, 2018, 3:16pm UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/37 "2018-08-20T15:16:11Z")

</div>

Thats ok, but this means that TOML.jl is currently not usable. Is the timeline days/weeks or are we talking about months? I will fork TOML.jl as TOML2.jl if this takes some time to get my package working on 0.7/1.0.

---

<div class="post-metadata">

**Author:** ![StefanKarpinski](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/stefankarpinski/32/24_2.png) [@StefanKarpinski](https://discourse.julialang.org/u/StefanKarpinski)\
**Post date:** [August 20, 2018, 3:17pm UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/38 "2018-08-20T15:17:21Z")

</div>

Sure, that seems like a reasonable interim solution. You could also ask @wildart to rename and register his package and maybe upstream the changes from the copy in stdlib.

---

<div class="post-metadata">

**Author:** ![chakravala](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/chakravala/32/6832_2.png) [@chakravala](https://discourse.julialang.org/u/chakravala)\
**Post date:** [August 21, 2018, 5:57am UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/39 "2018-08-21T05:57:35Z")

</div>

> [@tobias.knopp](#):
>
> Hm, we need a workaround for this because it makes depending on the TOML package impossible.

No, it’s not impossible. You can manually clone the package and add it to the manifest, or you can use the `Pkg.TOML` module that is already provided in stdlib.

> <https://github.com/chakravala/VerTeX.jl/blob/master/Project.toml>

This works perfectly fine for me, although it’s not an ideal situation.

---

<div class="post-metadata">

**Author:** ![tobias.knopp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tobias.knopp/32/7551_2.png) [@tobias.knopp](https://discourse.julialang.org/u/tobias.knopp)\
**Post date:** [August 21, 2018, 6:41am UTC](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319/40 "2018-08-21T06:41:10Z")

</div>

> [@chakravala](#):
>
> …, or you can use the `Pkg.TOML` module that is already provided in stdlib.

No that does not work since Pkg.TOML is broken and cannot read Arrays of floats.

[Previous page](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319.md?page=1)

[Next page](https://discourse.julialang.org/t/how-to-solve-problem-with-toml-jl/9319.md?page=3)
