[GNC] Finance::Quote enters previous day's price as today's

David Reiser dbreiser at icloud.com
Wed Jun 24 10:45:23 EDT 2020


> On Jun 24, 2020, at 3:00 AM, Colin Arndt <lumicanis at gmail.com> wrote:
> 
> Interesting. It still sounds like a bug report is in order if it’s storing an incorrect price after normal user interaction with the feature. The bug is that it’s storing a new price for the day before there is a new price for the day, and only correcting it after it gets the day’s price. I can adjust my behavior to avoid this, but it will affect other people in the future. Does that sound reasonable?
> 

It’s more like a policy dispute between you and the likes of yahoo finance. Yahoo has decided that they will account for any overnight corrections to funds' prior day closing by coughing up a pre-market quote with today’s date and yesterday’s adjusted closing price. Most pre-market quotes will be exactly the same as yesterday’s early evening reported closing price, but not always. 

If the data broker hands finance-quote a valid date and a valid price, there’s no way gnucash can determine that it should ignore the data record.

It looks like the part of alphavantage that finance-quote uses comes closer to what you want than yahoo does, but then it wasn’t possible to get a quote of Monday’s close of VTSAX from alphavantage+finance quote (at least not on Tuesday—I don’t know about Monday night). Perhaps alphavantage’s policy is that any overnight corrections block any outgoing price quote for the corrected day for that fund, at least as far as “yesterday’s closing price” is concerned.

> Thanks for your help everyone.
> 
> Matt, I’m on Linux not Windows, but I’d love to have your script as a starting point in case I go the import route. Thanks for the offer.
> 
> On Wed, Jun 24, 2020 at 12:40 AM David Reiser <dbreiser at icloud.com <mailto:dbreiser at icloud.com>> wrote:
> 
> > On Jun 23, 2020, at 4:10 PM, David Carlson <david.carlson.417 at gmail.com <mailto:david.carlson.417 at gmail.com>> wrote:
> > 
> > I am not sure that this is your problem or not, but I have found that I
> > need to wait several hours after the markets have closed before downloading
> > mutual fund prices.  It seems to take hours for some of them to get posted
> > at Yahoo.com. One way to check would be to see what Yahoo.com is reporting
> > early after hours vs later.
> > 
> > GnuCash only keeps one downloaded price per day, and repeated prices are
> > discarded.  If you see that is what is happening, you might file a RFE to
> > keep the last price reported instead of the first.
> > 
> > 
> On my test today, gnucash did save the most recent downloaded price for today, not the first.
> 
> Fund prices can get weird, depending on data feed and intermediaries. Yahoo as JSON was reporting an 8am price for today that was slightly different from yesterday’s close for all three of these Vanguard funds. Alphavantage, as of 6:30pm today (Tuesday) was still reporting Friday’s price for these funds.
> 
> Yahoo got today’s closing NAV for VTIAX and VWELX at 5:39 pm (EDT). The VTSAX price didn’t update until 6:00pm.
> 
> 
> 
> > 
> > .
> > 
> > On Tue, Jun 23, 2020 at 2:19 PM Colin <lumicanis at gmail.com <mailto:lumicanis at gmail.com>> wrote:
> > 
> >> First off, I just installed GnuCash a couple weeks ago, after trying a few
> >> other options and finding they simply weren't mature enough or
> >> feature-complete enough for what I need. I can't say thank you enough to
> >> everyone who's developed this program, everyone who continues to develop it
> >> and everyone who provides support here. It's an incredible accomplishment!
> >> 
> >> I have an issue with Finance::Quote. It brings in prices for my three
> >> Vanguard funds when I run the following command, and I've been planning on
> >> setting up a cron job for it:
> >> gnucash --add-price-quotes path/to/my/gnucash/file
> >> However, for one fund (VTSAX) it enters the prior day's price again as
> >> today's. This requires me to look it up and fix it manually. Its settings
> >> under Security editor are the same as the other two (VTIAX and VWELX).
> >> They're set to get online quotes from a single source, Alphavantage.
> >> Can anyone provide guidance on what may be going on here?
> >> Second question:
> >> I have a Raspberry Pi and it would make sense to run the cron job there
> >> since it's always up. I also use Syncthing for syncing files between
> >> devices. However, the latest version in their repo's is GnuCash 3.4 and
> >> Finance::Quote 1.47. Would this introduce problems to have the Pi update my
> >> GnuCash file with price quotes?
> >> 
> >> Thank you,
> >> Colin
> 
> 
> --
> Dave Reiser
> dbreiser at icloud.com <mailto:dbreiser at icloud.com>
> 

--
Dave Reiser
dbreiser at icloud.com







More information about the gnucash-user mailing list