[GNC] Finance quote troubleshooting

Geoff cleanoutmyshed at gmail.com
Fri Sep 11 20:59:19 EDT 2020


Dear Andreas

Did you set your Alphavantage key as an environment variable before you 
ran this test script?  Try entering these commands first:

set ALPHAVANTAGE_API_KEY=__Your_Actual_Key__
echo %ALPHAVANTAGE_API_KEY%

See attached screenshot.

See also this long thread on resolving a perl related currency problem 
on Windows:

http://gnucash.1415818.n4.nabble.com/GNC-Difficulty-with-online-price-retrieval-John-Ralls-tc4720222.html

Regards

Geoff
=====


On 12/09/2020 7:34 am, Andreas Vyrides wrote:
> Dear Mr Ralls,
> 
> It turn out you were able to correctly identify the issue for me since I 
> am not able to access the server. I am copying below the results after 
> running each command provided. I would be grateful if you could guide me 
> to resolve this issue.
> 
> "
> 
> C:\Program Files (x86)\gnucash\bin>perl 
> c:\strawberry\cpan\build\Finance-Quote-1.49-0\Examples\currency-lookup.pl GBP 
> EUR
> Urgh!  Nothing back
> 
> "
> 
> and
> 
> "
> 
> C:\Program Files (x86)\gnucash\bin>perl 
> c:\strawberry\cpan\build\Finance-Quote-1.49-0\Examples\stockdump.pl 
> alphavantage CSCO
> $VAR1 = {
>            'CSCO∟errormsg' => 'Internal Server Error',
>            'CSCO∟success' => 0
>          };
> 
> "
> 
> I apreciate all your help.
> 
> Kind Regards
> 
> Andreas Vyrides
> 
> On 11/09/2020 22:03, John Ralls wrote:
>> Dear Mr. Vyrides,
>>
>> Please remember to copy the list on all replies.
>>
>> Try testing Finance::Quote directly:
>>
>> set ALPHAVANTAGE_API_KEY=<your key>
>> perl 
>> c:\strawberry\cpan\build\Finance-Quote-1.49-0\Examples\currency-lookup.pl 
>> GBP EUR
>>
>> If that fails, try
>> perl 
>> c:\strawberry\cpan\build\Finance-Quote-1.49-0\Examples\stockdump.pl 
>> alphavantage CSCO
>> to make sure that you can successfully query alphavantage.
>>
>> Regards,
>> John Ralls
>>
>>
>>
>>> On Sep 9, 2020, at 10:27 PM, Andreas Vyrides <vyrasv at gmail.com> wrote:
>>>
>>> Dear Mr Ralls,
>>>
>>> Thank you for your prompt response
>>>
>>> Yes I have been through both gnc-fq-check which does not produce any 
>>> errors
>>>
>>> "
>>>
>>> C:\Program Files (x86)\gnucash\bin>perl gnc-fq-check
>>> ("1.49" "adig" "aex" "aiahk" "alphavantage" "amfiindia" "asegr" "asx" 
>>> "aufunds" "australia" "bamosz" "bet" "bmonesbittburns" "bourso" "bse" 
>>> "bsero" "canada" "canadamutual" "citywire" "cominvest" "cse" "deka" 
>>> "dutch" "dwsfunds" "europe" "fetch_live_currencies" "fidelity" 
>>> "fidelity_direct" "fidelityfixed" "financecanada" "finanzpartner" 
>>> "finland" "fool" "france" "ftfunds" "ftportfolios" 
>>> "ftportfolios_direct" "fundlibrary" "goldmoney" "greece" "hex" "hu" 
>>> "hufund" "hungary" "hustock" "iexcloud" "indiamutual" 
>>> "known_currencies" "lerevenu" "maninv" "morningstar" "morningstarau" 
>>> "morningstarch" "morningstarjp" "mstaruk" "nasdaq" "nyse" "nz" "nzx" 
>>> "platinum" "romania" "seb_funds" "sixfunds" "sixshares" 
>>> "stockhousecanada_fund" "tdefunds" "tdwaterhouse" "tiaacref" "tnetuk" 
>>> "troweprice" "troweprice_direct" "trustnet" "tsp" "tsx" 
>>> "uk_unit_trusts" "ukfunds" "unionfunds" "usa" "usfedbonds" "vanguard" 
>>> "vwd" "yahoo_json" "yahoo_yql" "za" "za_unittrusts")
>>>
>>> "
>>>
>>> and echo (yahoo_json "CSCO") | perl gnc-fq-helper which produces the 
>>> following result:
>>>
>>> "
>>>
>>> C:\Program Files (x86)\gnucash\bin>echo (yahoo_json "CSCO") | perl 
>>> gnc-fq-helper
>>> (("CSCO" (symbol . "CSCO") (gnc:time-no-zone . "2020-09-09 12:00:00") 
>>> (last . #e40.13) (currency . "USD")))
>>>
>>> "
>>>
>>> I forgot to mention in my previous email that I have already tried 
>>> completely removing and reinstalling both gnucash, and strawberryperl 
>>> with not avail.
>>>
>>> I hope this was helpful.
>>>
>>> Kind Regards
>>>
>>> DNR
>>>
>>> On 10/09/2020 03:30, John Ralls wrote:
>>>>> On Sep 9, 2020, at 6:44 AM, Andreas Vyrides <vyrasv at gmail.com>
>>>>>   wrote:
>>>>>
>>>>> Dear Sir,
>>>>>
>>>>> I have been having some trouble retrieving currency quotes from 
>>>>> Perl using Finance::Quote. I am only interested in currency 
>>>>> exchange rates (have not attempted using anything else). I have 
>>>>> been going through all steps of the wiki, such as running "Install 
>>>>> online price Retrieval", even changing my alpha-vantage key by 
>>>>> requesting a new one. I have also tried to get quotes from outside 
>>>>> gnucash by using the terminal with the following result
>>>>>
>>>>> "
>>>>>
>>>>> C:\Program Files (x86)\gnucash\bin>gnucash-cli.exe --quotes get
>>>>> file://C:\Users\EoL\Documents\gnuCash\test\test.gnucash
>>>>>
>>>>> Found Finance::Quote version 1.49.
>>>>> * 14:35:49  WARN <gnc.scm> Unable to retrieve quotes for these items:
>>>>> CURRENCY:USD
>>>>>    CURRENCY:EUR
>>>>> Continuing with good quotes.
>>>>>
>>>>> "
>>>>>
>>>>> In my attempts to get a single exchange rate from the terminal I 
>>>>> get the following results
>>>>>
>>>>> "
>>>>>
>>>>> C:\Program Files (x86)\gnucash\bin>perl gnc-fq-dump currency EUR GBP
>>>>> 1 EUR = <unknown> GBP
>>>>>
>>>>> "
>>>>>
>>>>> I would like to ensure that I have tried using both API keys in the 
>>>>> appropriate "online quote" in the preferences settings, but every 
>>>>> time I try to get quotes I get an error with "unable to retrieve 
>>>>> quotes for these items: Currency: USD, Currency:EUR"
>>>>>
>>>>> I am currently using F::Q v1.49, and gnucash v4.1
>>>>>
>>>>> Thank you for your time and all your support
>>>>>
>>>> Have you read https://wiki.gnucash.org/wiki/Online_Quotes, in 
>>>> particular https://wiki.gnucash.org/wiki/Online_Quotes#Trouble_Shooting
>>>> ?
>>>>
>>>> Regards,
>>>> John Ralls
>>>>
>>>>
> _______________________________________________
> gnucash-user mailing list
> gnucash-user at gnucash.org
> To update your subscription preferences or to unsubscribe:
> https://lists.gnucash.org/mailman/listinfo/gnucash-user
> If you are using Nabble or Gmane, please see 
> https://wiki.gnucash.org/wiki/Mailing_Lists for more information.
> -----
> Please remember to CC this list on all your replies.
> You can do this by using Reply-To-List or Reply-All.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: gnc_currency_test.jpg
Type: image/jpeg
Size: 30982 bytes
Desc: not available
URL: <http://lists.gnucash.org/pipermail/gnucash-user/attachments/20200912/5836d68a/attachment-0001.jpg>


More information about the gnucash-user mailing list