Problems downloading stock quotes

Richard Geddes rich.geddes at
Sun Oct 14 20:47:41 EDT 2007

Hi Derek,

Thanks for replying (again)... recall that we did some troubleshooting
before.. same issue.

 After giving up on the install-uninstall macro type fix, I decided to
dig into Finance::Quote to see what I could find.  There is a test perl
script that is short.. I tried it, named it showstocks:

#!/usr/bin/perl -w
use strict;
use Finance::Quote;

@ARGV >= 2 or die "Usage: $0 exchange symbol symbol symbol ...\n";

my $exchange = shift;	# Where do we fetch our stocks from.
my @symbols = @ARGV;	# Which stocks are we interested in.

my $quoter = Finance::Quote->new;	# Create the F::Q object.

$quoter->timeout(30);		# Cancel fetch operation if it takes
				# longer than 30 seconds.

# Grab our information and place it into %info.
my %info = $quoter->fetch($exchange, at symbols);

foreach my $stock (@symbols) {
	unless ($info{$stock,"success"}) {
		warn "Lookup of $stock failed - ".$info{$stock,"errormsg"}.
	print "$stock:\t\t",
	      "Volume: ",$info{$stock,"volume"},"\t",
	      "Price: " ,$info{$stock,"price"},"\n";

Execution yields the following:

$0> ./showstocks usa IBM
Use of uninitialized value in concatenation (.) or string at
./showstocks line 20.
Lookup of IBM failed -
Not much debugging data.. line 20 refers to

warn "Lookup of $stock failed - ".$info{$stock,"errormsg"}

and I found that $info{$stock,"errormsg"} is not initialized.. which
means (I think) that there is no communication, implying I don't have
the right modules to establish a comm link or that the server is
ignoring the requests.

I found out that

Finance::Quote depends upon a number of other perl modules to
function correctly.  These modules include:


Not a perl expert.. How can I determine which modules are installed on
my system?


Derek Atkins wrote:
> What happens when you try gnc-fq-dump ?
> Maybe your quote source changed their website?
> -derek
> Richard Geddes <rich.geddes at> writes:
>> I was using GNUCash 2.0.5 on Ubuntu 7.04 for the last several months.  Set up some stock investments and downloaded stock prices with Tools -> Price Editor -> Get Quotes.  This worked ok until about 3 weeks ago.  Now I get a message "There was an unknown error while retrieving the price quotes." 
>> I did install a firewall management program called "Firestarter" between the time gnucash was working and when it stopped working... I've since  uninstalled Firestarter.  I tried getting stock quotes after stopping my firewall using "/etc/init.d/iptables stop".  No difference.
>> I also upgraded to gnucash 2.2.1.  No dice.
>> I uninstalled gnucash altogether and reinstalled it, but still getting the same message.
>> I even thought of uninstalling perl as the module gnucash uses to get the quotes is in perl... but, it seems that many apps on my system depend on perl... on my ubuntu system, if I try to uninstall perl, it also includes (to uninstall) pretty much all the apps I've installed.. does that sound correct...?  
>> Anyway, my beef isn't really with perl, although it seems that if there was something goes wrong with perl, alot of things depending on it would also go down.... I just want to get my stock quotes so I can see my current asset values to make decisions without pulling out the calculator.
>> Can someone help me troubleshoot this problem?  Thanks.
>> Richard
>> _______________________________________________
>> gnucash-devel mailing list
>> gnucash-devel at

More information about the gnucash-devel mailing list