2016-01-28 GnuCash IRC logs

01:28:52 *** fell has quit IRC
02:37:19 *** fell has joined #gnucash
02:37:20 *** gncbot sets mode: +o fell
02:37:37 *** gjanssens has joined #gnucash
02:37:37 *** ChanServ sets mode: +o gjanssens
03:02:14 *** uXus has quit IRC
03:08:53 *** uXus has joined #gnucash
04:07:41 *** rubdos has joined #gnucash
04:35:26 *** fell has quit IRC
05:01:51 *** nomeata has joined #gnucash
05:13:07 *** fabior has joined #gnucash
05:21:56 <g5pw> hello! any gnucash devs here? I'm a macports maintainer and wanted to build python support in gnucash. The issue is that gnucash installs python modules in $prefix/lib/python2.7/site-packages/ but I need it in $prefix/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages. I tried setting PYTHON_{SITE_PKG,PREFIX,EXEC_PREFIX} to the correct value but it looks like it's ignored by the build system...
06:40:12 *** Jimraehl1 has left #gnucash
06:44:52 *** Jimraehl1 has joined #gnucash
07:28:51 *** fabior has quit IRC
07:36:06 *** finster has joined #gnucash
08:21:11 <finster> hello all. I'm trying to get my head around gnucash (2.6.11, OSX Intel).
08:22:18 <finster> how can I allocate e. g. 200$ as planned expenses for food and review if i met/missed that goal, preferably on a monthly basis? I figure budgeting is the way to go, but do I have to enter the forecasted values all manually?
08:26:49 <finster> also, is there a way to limit a given budget so it shows only certain accounts?
08:34:08 *** redarrow has quit IRC
08:42:01 <g5pw> finster i think you have to do it manually, yes. Gnucash can estimate the budget based on previous expenses though...
08:46:08 *** redarrow has joined #gnucash
08:47:33 <finster> I see. thanks for the answer, g5pw
09:00:27 *** fabior has joined #gnucash
09:44:54 *** aqua___ has joined #gnucash
10:21:48 *** aqua___ has quit IRC
10:58:30 *** finster has left #gnucash
10:58:44 *** nomeata has quit IRC
11:09:07 <codesmythe> g5pw: Site-package detection for Python is done in aclocal.m4 by asking the python interpreter itself. It uses functions in distutils.sysconfig for 2.7, or just sysconfig in other versions.
11:09:46 <codesmythe> g5pw: I could not convince functions in those packages to return the path you want.
11:14:59 *** rubdos has quit IRC
11:19:04 *** fell has joined #gnucash
11:19:05 *** gncbot sets mode: +o fell
12:00:47 *** fabior has quit IRC
12:10:45 <jralls> fell: libchipcard is not in Gnucash.app. It's not in the Windows build either FWIW. IIRC I experimented with it in 2013 but couldn't get libaqbanking to actually use it. Since it's tech that isn't used in the US (or anywhere outside of Germany IIUC) I can't really test anything. Do you know enough about AQB to get it to work?
12:14:11 *** fabior has joined #gnucash
12:19:42 <jralls> gjanssens: re C++11, not only are we using it, we should emphasize it, coding in C++11 style as much as possible. auto, range-for, lambdas, the TR1 and C++11 std library classes (most replace boost stuff). Lambdas in particular, they make using the std algorithms much easier.
12:21:19 <fell> jralls, I am using Aqbanking, but only the PIN/TAN method. I have no cardreader.
12:23:42 <jralls> fell: OK. Can you find out if anyone on the de list uses a cardreader with GnuCash?
12:24:33 <fell> AFAIK, Martin Preuss works for a manufactorer.
12:25:59 <jralls> codesmythe, gjanssens: Re libboost::locale, it depends on ICU. IMO that's a good thing, ICU is the gold standard for localization, and because WebKit also depends on it we do already. gjanssens, you might look into using it directly instead of with boost::locale and C++ localization facets in the middle.
12:27:10 <fell> And yes, on gnucash-de and aqbanking-user are sometimes Q&A about the different chipcards.
12:34:15 <jralls> fell: OK, I wanted to make sure that GnuCash could talk to libchipcard before going to Martin about configuring AQB.
12:37:04 *** rubdos has joined #gnucash
12:37:11 * jralls going down for a OS update. Back in a bit.
12:37:16 *** jralls has quit IRC
12:45:54 *** jralls has joined #gnucash
12:45:54 *** ChanServ sets mode: +o jralls
12:53:16 <fell> jralls, at least the mutual Sparkassen use DDV cards, which follow an open standard and can be used with aqbanking.
12:56:02 <jralls> fell: OK. I guess. The issue isn't so much about AQBanking as the way GnuCash uses AQBanking. Martin has his own client program, AQFinance, that IIUC uses AQB features which GnuCash doesn't. There's no point in adding libchipcard to the AIO bundles if GnuCash's AQB interface can't use it.
12:57:16 <fell> I know about german users, using chipcards in gnucash over 10 years.
12:59:17 <fell> Usually cstim or Micha Lenk implemented the required parts in GnuCash.
13:12:04 *** codesmythe has quit IRC
13:15:05 <gjanssens> jralls: re c++11, I'll have to grow into it
13:15:21 <gjanssens> I'll put up my first experiments for review when I think they're worth it
13:15:36 <gjanssens> I'll be happy to get your feedback on it
13:15:47 *** gjanssens is now known as gjanssens_afk
13:16:58 <jralls> gjanssens_afk: Yeah, I'm not surprised. Meyers's "Effective Modern C++" is the best bootstrapper I've found so far, but it's expensive.
13:30:18 *** minot has quit IRC
13:44:12 *** fabior has quit IRC
14:03:39 *** bertbob has quit IRC
14:11:33 *** bertbob has joined #gnucash
14:18:39 *** codesmythe has joined #gnucash
14:21:09 <Cork> where is the settings stored?
14:21:26 <Cork> i'm trying to set the currency but it keeps resetting to usd for me
14:23:20 <fell> Cork, see http://wiki.gnucash.org/wiki/Locale_Settings
14:24:00 <Cork> ya,i know that i can change the locale, but that doesn't really help me, i need to find where the settings are stored
14:24:34 <fell> depends on your gnucash version and OS
14:24:44 <Cork> latest and linux
14:25:09 <Cork> i've checked .gnucash/ but can't find anything related
14:25:59 <Cork> the problem is that i'm running --add-quotes and it still uses the wrong currency even though i've changed both locale and settings :/
14:27:04 <fell> How do you run --add-quotes?
14:27:25 <warlord> Cork: which particular "currency setting" are you trying to change?
14:27:33 <fell> http://wiki.gnucash.org/wiki/FAQ#Q:_How_do_I_backup_my_GC_environment.2C_including_preferences.3F
14:28:40 <Cork> well first i changed accounts > default currency to choose and my currency
14:29:01 <Cork> but that reset back to locale every time i restarted gnucash
14:29:16 <Cork> so i created a custom locale with the correct currency
14:29:24 <Cork> so now it syas locale: my currency
14:29:24 <warlord> exactly what version of gnucash?
14:29:33 <Cork> but --add-quotes still uses usd isntead
14:29:43 <Cork> 2.6.10
14:30:02 <fell> outdated ;-)
14:30:23 <fell> may be http://wiki.gnucash.org/wiki/Online_Quotes#cron_and_Non-X_Usage
14:30:31 <warlord> the accounts->default currency only sets the currency selected by default when you create accounts. It doesn't affect the "default currency", which is from the locale.
14:31:33 *** rubdos has quit IRC
14:31:53 <Cork> warlord: well it affects what price editor > get quotes does
14:32:19 <Cork> if it says usd it fetches currency convertion from all currences you use to usd
14:32:30 <Cork> if it says your currency it fetches to that currency instead
14:32:43 <Cork> so, again where is this settings stored?
14:33:03 <warlord> the locale
14:33:07 <Cork> no
14:33:20 <Cork> locale is an option you can choose to use
14:33:33 <Cork> there is an option to set a specific currency too
14:33:39 <warlord> Where?
14:33:47 <Cork> accounts > defualt currency
14:34:04 <warlord> Like I said, that only sets the default currency used when you create new accounts.
14:34:05 <Cork> the option "Choose"
14:36:03 <Cork> anyone?
14:36:19 <warlord> I'm not familiar with the get quotes currency conversion so I'm not sure how to control that. What exactly are you trying to get it to do?
14:36:30 <warlord> (please be specific about what you're trying to get it to do)
14:36:46 <Cork> i'm trying to find where this graphical option is storing the setting...
14:37:00 <warlord> dconf
14:37:32 <warlord> All Edit -> Preferences are stored in DConf
14:37:35 <warlord> (on Linux)
14:37:59 <Cork> thx
14:38:38 <warlord> But you still didn't answer my question about what you're trying to do, because that particular setting WONT AFFECT QUOTES
14:39:08 <Cork> well it does
14:39:10 <fell> Hm, AFAIK, the base currency of shares etc. is derived from the (parent) account or the first txn.
14:39:48 <fell> And for currencies in the price editor.
14:40:04 <warlord> fell: yes, when you create a new transaction in a share account it uses the currency of the parent account.
14:40:11 <Cork> for currencies it will base all currencies on the default currency
14:40:14 <warlord> Cork: are all your share accounts subaccounts of a currency-based account?
14:40:25 <warlord> Or are they root accounts?
14:40:26 <Cork> so unless it says your currency you will have to convert to usd and then to all other currencies
14:40:42 <Cork> cause the download won't fetch it towards your currency
14:41:20 <warlord> s/root/top-level
14:41:48 <Cork> warlord: it doesn't matter
14:42:18 <warlord> Cork: please answer my questions and don't assume you know better than us.
15:05:24 *** fabior has joined #gnucash
15:09:07 *** gjanssens_afk is now known as gjanssens
15:09:48 <gjanssens> jralls: thanks for the pointer to Meyers's "Effective Modern C++"
15:09:59 <gjanssens> Will be delivered at my desk tomorrow :)
15:10:23 <gjanssens> I'm almost afk for tonight...
15:10:45 <gjanssens> If you like to see my work so far, I have pushed it to https://github.com/gjanssens/gnucash/tree/cpp
15:11:23 <gjanssens> I've converted the part that loads a file and converts it into a table of strings so far
15:11:43 <gjanssens> Still need to have a look at the part that converts the table of strings into actual transactions
15:11:52 <gjanssens> And then take on the assistant's code
15:12:38 <gjanssens> Unfortunately the code is not isolated at all. The assistant is accessing variables deep in the old parser's info struct.
15:13:12 <gjanssens> That means I will have to make changes to the assistant code to work with the c++ classes
15:13:32 <gjanssens> Not that bad in itself as it's still a fairly self-contained project
15:13:35 <jralls> gjanssens: Yeah, unfortunately Bob Fewell doesn't really get architecture.
15:14:22 <gjanssens> Well, my work should clean up big parts of that
15:14:41 <jralls> That will be great.
15:15:01 <gjanssens> As to boost::locale vs icu directly
15:15:05 <jralls> I keep resisting the temptation to dive into the mess of Reg2.
15:15:39 <gjanssens> I first intended to use the facet as found in the boost::locale documentation
15:16:11 <gjanssens> However there was a note that this won't work with stateful encodings (such as some Asian encodings use)
15:16:29 <gjanssens> So instead I am using to_utf() for now.
15:16:55 <warlord> I'd love to see "Reg2" completed. Of course I suspect we might need to almost restart from scratch.
15:16:57 <gjanssens> The side effect is I'm copying more strings around though, which may negatively impact performance
15:17:13 <gjanssens> warlord: likely
15:17:36 <gjanssens> And as a confession: I also have been tempted more than once to dig into it :)
15:18:04 <jralls> More than likely, I'm afraid. It's really ugly. Loads of copy and paste from Reg1 splattered all over the place.
15:18:04 <gjanssens> I chose csv import first because that will allow us to drop our goffice dependency
15:20:13 <gjanssens> jralls: I read in your reply on the "Posted" time patch you won't have much time the next few weeks...
15:20:24 <gjanssens> For positive reasons I may hope ?
15:21:12 <jralls> gjanssens: Actually until a week from Monday. One of my two annual genealogy conferences.
15:21:23 <warlord> gjanssens: use references or ref-counting to avoid copying
15:22:10 <jralls> No, use std::shared_ptr to avoid both copying and to avoid hand-rolling ref-counting.
15:22:38 <gjanssens> warlord: is that a code review of my github link, or a reaction on my comment re to_utf() vs facets ?
15:22:57 <jralls> std::make_shared will allocate and create the shared ptr in one go with a tighter struct.
15:23:23 <gjanssens> jralls: my code for now hardly uses any pointers at all
15:23:27 <gjanssens> at least not directly
15:23:37 <gjanssens> It's all std:vector and std::string
15:23:51 <jralls> Really? Everything's on the stack?
15:24:28 <gjanssens> Hmm, that sounds as if I'm doing something poorly :(
15:25:27 <jralls> Looking at gnc-fw-tokenizer.cpp, you have empty constructor and destructor impls. If you don't need to do anything special just declare them in the header with the default keyword and the compiler will take care of it.
15:26:26 <jralls> Note that in C++11 the rule of 3 becomes the rule of 5 because you have move constructor and operator= as well as the copy ones.
15:27:10 <gjanssens> "Rule of 3?" - constructor/destructor and ?
15:27:34 <warlord> gjanssens: it's a reaction to your comment that you're copying strings and worrying about performance.
15:27:46 <jralls> Destructor, Copy Constructor, and copy operator=().
15:28:11 <gjanssens> jralls: Ok, I saw several of those in the STL documentation indeed.
15:28:34 <gjanssens> I'll see how to add them to my classes
15:29:06 <gjanssens> warlord: ok. It's std::string actually combined with std::vector
15:29:15 <warlord> jralls: well, std::shared_ptr is a ref-counter, effectively :)
15:29:15 <gjanssens> I don't know how well STL optimizes this internally
15:30:01 <warlord> gjanssens: AFAIK it doens't -- it'll copy from one std::string to another std::string, but if you use references then it wont copy.
15:30:01 <gjanssens> And I'm not into performance tuning yet. For now I first have to get to a state where I can *run* gnucash with the new code :)
15:30:18 <warlord> Or you use a shared_ptr
15:30:46 <gjanssens> warlord: except that it has to do a conversion step in between from <file encoding> to utf-8, so it's effectively two different strings
15:31:15 <jralls> The compiler will create them for you unless you create one of them yourself. If you do then you're on the hook to do all of them unless you declare them with the default keyword. Meyers's guidance is to always declare all 5 with either default (if you want the compiler to do it), delete (if you want to not have it), or with an implementation if that's what you need.
15:31:48 <gjanssens> Ok, thanks
15:32:37 <gjanssens> I'll talk with Meyers tomorrow :)
15:32:41 <jralls> If you're using std::string they're always allocated and you get back a ptr which you need to either delete explicitly or wrap in std::shared_ptr or std::unique_ptr which will manage the lifetime for you.
15:33:23 <gjanssens> Will the std::string not be unallocated automatically when it goes out of scope ?
15:33:35 <gjanssens> (on stack obviously)
15:34:33 <warlord> gjanssens: yes, if it's on the stack it will be deallocated when it goes out of scope.
15:34:53 <warlord> But if you pass it by value into another function the contents will be copied.
15:35:19 <gjanssens> Ok, understood
15:36:45 <gjanssens> I'll have to fix that part for sure (and refresh my memory on pass by reference vs pass by value in c++)
15:37:15 <warlord> it's all about the function declaraction
15:37:27 <warlord> foo(std::string x) is pass by value
15:37:39 <warlord> foo(std::string &x) is pass by reference
15:37:55 <warlord> (and of course foo(std::string *x) is pass by pointer)
15:38:04 <gjanssens> thanks
15:38:27 <gjanssens> How about return values (ie I'll have to return a value by reference)
15:38:41 <gjanssens> std::string &foo(bla) ?
15:39:08 <warlord> Generally it's bad to return-by-reference unless you are SURE it wont go out of scope.
15:39:47 <gjanssens> Hmm, ok
15:40:21 <gjanssens> No worries, I'll check the existing c++ parts in libqof for examples
15:41:00 <gjanssens> Anyway. I have to leave for tonight
15:41:31 <gjanssens> Thanks for the hints and (initial) feedback
15:41:37 <gjanssens> See you later
15:42:06 *** gjanssens has quit IRC
15:53:49 *** fell_ has joined #gnucash
15:55:59 *** fell has quit IRC
15:58:54 *** fell_ is now known as fell
15:59:12 *** gncbot sets mode: +o fell
16:01:49 <fell> Qantourisc, you were searching the File->Properties->Accounts->Day Threshold for Read-Only Transactions
16:02:21 <Qantourisc> fell: ow also sounds intresting
16:42:05 *** fabior has quit IRC
17:52:50 *** minot has joined #gnucash
18:11:35 *** codesmy38 has joined #gnucash
18:11:38 *** codesmythe has quit IRC
18:14:41 *** codesmy38 has quit IRC
18:15:06 *** codesmythe has joined #gnucash
18:58:15 *** codesmythe has quit IRC
19:01:39 *** codesmythe has joined #gnucash
19:05:23 *** codesmy41 has joined #gnucash
19:06:24 *** codesmythe has quit IRC
19:32:58 *** codesmy41 has quit IRC
19:33:21 *** codesmythe has joined #gnucash
19:46:20 *** bertbob has quit IRC
19:46:39 *** bertbob has joined #gnucash
19:56:10 *** codesmythe has quit IRC
19:57:17 *** codesmythe has joined #gnucash
20:10:23 *** codesmythe has quit IRC
20:11:23 *** codesmythe has joined #gnucash
23:13:58 *** minot has quit IRC