Subject: | VWD.pm assigns bogus time to quotes outside trading hours |
at line 134 of VWD.pm:
my $time = $wpkurs->look_down(
"_tag", "div",
"class", "datum"
);
if ($time) {
$info{$fund, "time"} = $time->as_trimmed_text;
}
During trading hours, "datum" contains a time as hh:mm:ss. After hours,
datum returns a date as dd.mm.yy
gnucash insists on a valid time to use a quote, so gnucash users can't
use VWD values when $time=30.04.09 for example.
Also, $date is set by the value at the top of the page, which is the
date the quote is retrieved, not the date associated with the quote
(unless of course it's during trading hours).
It looks like the module should examine datum and either use it for
time, or else use it for the date as appropriate. I'd be in favor of the
module also assigning a time in the second case -- something like
18:00:00 that's clearly outside the trading day, but not so close to
midnight that a small time zone change causes issues. I suppose maybe
the time might be best as UTC for closing time, but I'm not so sure
that's the best or not.