[GNC] Currency exchange rates retrieval with GC 3.2

Manfred Usselmann manfred at usselmann.de
Thu Sep 6 12:21:33 EDT 2018


 

Am 06.09.2018 16:33, schrieb John Ralls: 

>> On Sep 6, 2018, at 12:15 AM, Manfred Usselmann <manfred at usselmann.de> wrote:
>> 
>> Hi, 
>> 
>> I'm using GnuCash 3.2 with Finance::Quote 1.47 on Ubuntu 18.04. 
>> 
>> When trying to download currency exchange rates this fails with "Unknown
>> error". 
>> 
>> I've registered an ALPHAVANTAGE_API_KEY and entered it on the settings
>> screen. 
>> 
>> Some tests from the command line: 
>> 
>> $ GNC-FQ-DUMP -V ALPHAVANTAGE CHFEUR=X
>> Finance::Quote fields Gnucash uses:
>> symbol: CHFEUR=X <=== required
>> date: 09/06/2018 <=== recommended
>> currency: USD <=== required
>> last: 0.8842 <=\ 
>> nav: <=== one of these
>> price: <=/ 
>> timezone: <=== optional 
>> 
>> All fields returned by Finance::Quote for stock CHFEUR=X 
>> 
>> stock field value
>> ----- ----- -----
>> CHFEUR=X close: 0.8842
>> CHFEUR=X currency: USD
>> CHFEUR=X currency_set_by_fq: 1
>> CHFEUR=X date: 09/06/2018
>> CHFEUR=X high: 0.8847
>> CHFEUR=X isodate: 2018-09-06
>> CHFEUR=X last: 0.8842
>> CHFEUR=X low: 0.8840
>> CHFEUR=X method: alphavantage
>> CHFEUR=X open: 0.8845
>> CHFEUR=X success: 1
>> CHFEUR=X symbol: CHFEUR=X
>> CHFEUR=X volume: 0 
>> 
>> $ ECHO '(ALPHAVANTAGE "CSCO")' | GNC-FQ-HELPER
>> (("CSCO" (symbol . "CSCO") (gnc:time-no-zone . "2018-09-05 12:00:00")
>> (last . 47.2700) (currency . "USD")))
> 
> Does the CSCO price retrieval work in GnuCash?

No, also got unknown error. I'm not sure though that I set it up
correctly. The command line was just copied from somewhere, the wiki I
believe. 

> I created a CHFEUR=X security, set it to retrieve quotes from Alphavantage, and successfully retrieved the price in GnuCash.

I did not create a security, just a currency account. 

> Note, however, that it's not a meaningful value: CHFEUR=X retrieves the price in EUR of 1CHF, but Finance::Quote treats it as USD because Alphavantage doesn't tell it otherwise.

Mmh, but the manual says to use Alphavantage for currencies? 

Are there any instructions which should work. I just want to download
exchange rates... ;-) 

Unknown error is not really helpful... The exact error message is "Beim
Herunterladen der Börsenkurse ist ein unbekannter Fehler aufgetragen." 

Regards,
Manfred 

> Regards,
> John Ralls

 


More information about the gnucash-user mailing list