With the following program on GHC 8.10.7, conferer 1.1.0.0:
data Foo = Foo { secret :: Text }
appMain :: IO ()
appMain = do
cfg <- mkConfig' [] [fromFilePath "config.properties"]
appConfig' <- fetchFromConfig @Foo "" cfg
exitSuccess
This compiles and runs, without deriving Generic or FromConfig. The application crashes with an exception:
app-exe: Failed to get a 'Foo' from keys: ""
Setting a secret key in config.properties doesn't help and the application continues to crash in the same manner.
Deliberately adding a blank instance of FromConfig, and deriving Generic fixes the problem, but there is no indication to do so.
With the following program on GHC 8.10.7, conferer 1.1.0.0:
This compiles and runs, without deriving
GenericorFromConfig. The application crashes with an exception:Setting a
secretkey inconfig.propertiesdoesn't help and the application continues to crash in the same manner.Deliberately adding a blank instance of
FromConfig, and derivingGenericfixes the problem, but there is no indication to do so.