Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Confix not able to resolve arrays values #21034

Closed
1 task done
GFSimone opened this issue Jul 23, 2024 · 1 comment
Closed
1 task done

[Bug]: Confix not able to resolve arrays values #21034

GFSimone opened this issue Jul 23, 2024 · 1 comment
Assignees
Labels

Comments

@GFSimone
Copy link

Is there an existing issue for this?

  • I have searched the existing issues

What happened?

It looks like Confix is not able to resolve simple nested arrays in TOML files.

Did not find any documentation describing proper syntax.

Cosmos SDK Version

No "version" param. I installed "latest" on 07/2024.

How to reproduce?

This is an example of nested values. How to retrieve "granny smith" value ?

[[fruit]]
  name = "apple"

  [[fruit.variety]]
    name = "red delicious"

  [[fruit.variety]]
    name = "granny smith"

The follow did NOT work to me:

confix get config.toml fruit.variety[1].name
confix get config.toml fruit.variety.1.name

@julienrbrt
Copy link
Member

julienrbrt commented Aug 6, 2024

Hey, so I have checked, it is indeed not supported. We could support some custom key parsing and not use doc.Find, however, I think I would appreciate it if the library we use could use this, and update doc.Scan to support what you ask.

I would invite you to reach out to the maintainer of github.com/creachadair/tomledit and ask if they can add this feature.
We'll be happy to bump once this is supported directly in doc.Scan.

@julienrbrt julienrbrt closed this as not planned Won't fix, can't repro, duplicate, stale Aug 6, 2024
@github-project-automation github-project-automation bot moved this from 📋 Backlog to 🥳 Done in Cosmos-SDK Aug 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: 🥳 Done
Development

No branches or pull requests

2 participants