[Kmymoney-devel] WebPriceQuote object
asoliverez at gmail.com
Mon Sep 14 12:51:22 CEST 2009
On Sun, Sep 13, 2009 at 11:26 PM, Fernando Vilas <fvilas at iname.com> wrote:
> I have made some progress on getting quotes working again, but I have a few
> questions that hopefully can be answered by someone who understands this
> object better than I do.
> There are several code paths for non-interactive executables, controlled by
> checking "if (! kapp)". kapp is always true, whether it is set to false in
> main() in kmymoney2/kmymoneytest.cpp or not. In the interest of simplicity
> and testability, I would like to remove these paths, leaving only the path
> followed when kapp is true. This also fixes the "fix for windows" warning
> WebPriceQuote::launchNative(). Any objections, or things I should consider?
> WebPriceQuote::launchNative() has a branch for executing a local file.
> is a separate class for handling the Perl Finance::Quote script, so I don't
> really know how to test this branch. Does anyone have an example, or would
> you suggest removing this branch, and creating a class similar to the one
> Finance::Quote if/when more scripts are added?
> WebPriceQuote::download() and related functions are private, and a
> reimplementation of parts of KIO::NetAccess. Before I change the code to
> call KIO::NetAccess::download(), does the original reason for the
> reimplementation still make sense? So far, I have commented out the bulk
> WebPriceQuote::download(), and just call the NetAccess version internally.
> As of right now, things seems to be working, both in the test driver, and
> main app. The test driver retrieves from Yahoo (US, UK, Currency), and
> Finance::Quote, but fails on the Globe & Mail and MSN. I have not built
> for the remaining sources, but I probably will, just to make things easier
> the future.
> If you want to see the changes, I can send a patch, or go ahead and commit
> changes. Don't forget to define PERFORM_ONLINE_TESTS, to see these tests.
Thomas may have the best info about this.
@Thomas, do you remember why any of these decisions were made at the time?
Were you involved in any of this back then?
I know there are some things in reports which I would have done differently,
so this might be the case.
If Thomas doesn't remember, Fernando, you can reassess, make sure the test
cases cover enough of the practical cases and go with your solution.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the KMyMoney-devel