Skip Menu |

This queue is for tickets about the Config-General CPAN distribution.

Report information
The Basics
Id: 33216
Status: resolved
Priority: 0/
Queue: Config-General

People
Owner: tlinden [...] cpan.org
Requestors: Allen.Conway [...] atosorigin.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: Interpolation problems
Date: Wed, 13 Feb 2008 17:32:42 +0100
To: <bug-Config-General [...] rt.cpan.org>
From: "Conway Allen" <Allen.Conway [...] atosorigin.com>
Hello, If you provide a default config definition things don't work as I would expect them to work - perhaps it's my expectations that are wrong! Given a config file like this: <abc> path /tmp bin $path/bin </abc> <xyz> path /tmp </xyz> and a default hash defined as %default = (abc => {path => '/usr/local'}, xyz => {path => '/usr/local', bin => '$path/bin'}); The config I get back is: {abc}{path} = /tmp {abc}{bin} = /usr/local/bin {xyz]{path} = /tmp {xyz}{bin} = $path/bin I would expect to get {abc}{path} = /tmp {abc}{bin} = /tmp/bin {xyz]{path} = /tmp {xyz}{bin} = /tmp/bin i.e I assumed interpolation to be the last thing done once all the data had been picked up from the config file and after having moved in the stuff from the default hash definitions. That doesn't seem to be the case at all ! best regards, Allen Conway
Well, it it happens during parsing, but default hash handling is somewhat special. So, I can confirm this as misbehavior, however I'm actually not sure how to fix it. Give me some time.
Fixed in 2.38