# Ordered TOML?

**URL:** https://discourse.julialang.org/t/ordered-toml/59278
**Category:** General Usage
**Tags:** question, package
**Created:** [April 14, 2021, 2:09pm UTC](https://discourse.julialang.org/t/ordered-toml/59278 "2021-04-14T14:09:34Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![Amval](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/amval/32/6217_2.png) [@Amval](https://discourse.julialang.org/u/Amval)
#### Post date: [April 14, 2021, 2:09pm UTC](https://discourse.julialang.org/t/ordered-toml/59278/1 "2021-04-14T14:09:34Z")

</div>

Hello everyone,

I am on the process of upgrading to Julia 1.6, which includes a `TOML` package as part of the base libraries.

Before, I was using my own `TOML`package, forked from [here](https://github.com/JuliaAttic/TOML.jl) to returned an `OrderedDict` instead of a regular one.

Checking the new implementation I see that changing this:

> const TOMLDict = Dict{String, Any}

to use an `OrderedDict` would probably be sufficient.

However maintaing my own fork is overkill, specially now that `TOML` is part of `Base`. Any ideas? Would it be possible to make a Pull Request to make the parser parametric? Maybe there is a good reason **not** to do this, in which case I would just maintain my own fork again.

Thanks in advance.

---

<div class="post-metadata">

### Author: ![pdeffebach](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/pdeffebach/32/10320_2.png) [@pdeffebach](https://discourse.julialang.org/u/pdeffebach)
#### Post date: [April 14, 2021, 2:12pm UTC](https://discourse.julialang.org/t/ordered-toml/59278/2 "2021-04-14T14:12:52Z")

</div>

I also encountered this while working with my own TOML for the first time. Was a bit bummed to find that it was unordered (and thus hard to make a DataFrame from).

---

<div class="post-metadata">

### Author: ![GunnarFarneback](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gunnarfarneback/32/1827_2.png) [@GunnarFarneback](https://discourse.julialang.org/u/GunnarFarneback)
#### Post date: [April 14, 2021, 2:23pm UTC](https://discourse.julialang.org/t/ordered-toml/59278/3 "2021-04-14T14:23:34Z")

</div>

A side observation is that this would be a non-issue if Julia’s default `Dict` was insertion ordered, [https://github.com/JuliaLang/julia/issues/34265#issuecomment-571020454](https://github.com/JuliaLang/julia/issues/34265#issuecomment-571020454).

---

<div class="post-metadata">

### Author: ![Amval](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/amval/32/6217_2.png) [@Amval](https://discourse.julialang.org/u/Amval)
#### Post date: [April 14, 2021, 2:28pm UTC](https://discourse.julialang.org/t/ordered-toml/59278/4 "2021-04-14T14:28:03Z")

</div>

I wouldn’t mind that, but it is surely a more ambitious change that what I had in mind 😛
