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

Reasonable derivation defaults for scala 3 #1204

Open
susliko opened this issue Nov 1, 2021 · 0 comments
Open

Reasonable derivation defaults for scala 3 #1204

susliko opened this issue Nov 1, 2021 · 0 comments

Comments

@susliko
Copy link

susliko commented Nov 1, 2021

Hi! It's nice to see scala 3 derivation for pureconfig. I understand, that ProductHints are not yet taken into account, however it seems misleading to convert kebab-case config keys into camelCase case class fields:

import $ivy.`com.github.pureconfig::pureconfig-core:0.17.0`
import pureconfig.generic.derivation.default._
import pureconfig._

case class Foo(fooBar: String) derives ConfigReader

ConfigSource.string("{fooBar: \"foo\"}").load[Foo]
// res0: Either[ConfigReaderFailures, Foo] = Left(ConfigReaderFailures(ConvertFailure(KeyNotFound(foo-bar,Set(fooBar)),None,foo-bar)))

Is it possible to change the default field renaming behaviour to identity?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant