2019-04-29 GnuCash IRC logs
00:00:53 *** storyjesse has joined #gnucash
01:08:55 *** marusich has joined #gnucash
01:08:57 *** ChanServ sets mode: +v marusich
01:19:37 *** fell has quit IRC
01:20:56 *** fell has joined #gnucash
01:20:56 *** ChanServ sets mode: +o fell
01:26:53 *** nimish2711 has joined #gnucash
01:40:57 *** nicoroumeau has joined #gnucash
01:54:39 *** fabior has joined #gnucash
01:58:08 *** nicoroumeau has quit IRC
02:03:06 *** nimish2711 has quit IRC
02:16:07 *** mpiechotka has joined #gnucash
02:16:07 *** ChanServ sets mode: +v mpiechotka
02:40:56 *** mpiechotka has quit IRC
02:41:07 *** fabior has quit IRC
02:41:44 *** mpiechotka has joined #gnucash
02:41:44 *** ChanServ sets mode: +v mpiechotka
02:42:17 *** marusich has quit IRC
02:43:25 *** mpiechotka has quit IRC
02:43:56 *** mpiechotka has joined #gnucash
02:43:56 *** ChanServ sets mode: +v mpiechotka
02:44:45 *** mpiechotka has quit IRC
02:45:12 *** mpiechotka has joined #gnucash
02:45:12 *** ChanServ sets mode: +v mpiechotka
02:54:56 *** mpiechotka has quit IRC
03:23:07 *** mpiechotka has joined #gnucash
03:23:08 *** ChanServ sets mode: +v mpiechotka
03:23:12 *** mpiechotka has quit IRC
03:23:27 *** mpiechotka has joined #gnucash
03:23:37 *** ChanServ sets mode: +v mpiechotka
03:24:37 *** Mechtilde has joined #gnucash
03:28:00 *** mpiechotka has quit IRC
03:41:25 *** ChanServ sets mode: +v Mechtilde
04:56:05 *** Aussie_matt has quit IRC
05:09:13 *** KevinDB has quit IRC
05:11:14 *** KevinDB has joined #gnucash
05:11:15 *** ChanServ sets mode: +v KevinDB
05:24:29 *** KevinDB has quit IRC
05:25:07 *** KevinDB has joined #gnucash
05:25:07 *** ChanServ sets mode: +v KevinDB
05:34:15 *** Aussie_matt has joined #gnucash
05:35:24 *** Aussie_matt has quit IRC
05:39:56 *** Aussie_matt has joined #gnucash
05:47:31 *** gjanssens has joined #gnucash
05:47:32 *** ChanServ sets mode: +o gjanssens
05:47:38 <gjanssens> .
06:30:25 *** oozer has joined #gnucash
06:38:57 <warlord> .
07:18:21 *** ecdhe has quit IRC
07:27:24 *** fabior has joined #gnucash
07:30:50 *** ecdhe has joined #gnucash
07:33:20 *** fabior has quit IRC
08:03:56 *** Aussie_matt has quit IRC
08:31:32 *** fell has quit IRC
08:32:16 *** fell has joined #gnucash
08:32:16 *** ChanServ sets mode: +o fell
08:38:57 *** oozer has quit IRC
08:53:08 *** warlord has quit IRC
08:56:51 *** warlord has joined #gnucash
08:56:51 *** gncbot sets mode: +o warlord
08:58:25 *** jervin has joined #gnucash
09:07:16 *** jervin has quit IRC
09:45:50 *** jervin has joined #gnucash
09:47:06 *** jervin has quit IRC
09:47:12 *** warlord has quit IRC
09:52:47 *** nimish2711 has joined #gnucash
09:55:01 *** warlord has joined #gnucash
09:55:02 *** gncbot sets mode: +o warlord
10:11:28 *** nimish2711 has quit IRC
10:11:29 *** nimish2711_ has joined #gnucash
10:12:01 *** nimish2711_ is now known as nimish2711
10:23:10 *** nimish2711_ has joined #gnucash
10:23:50 *** nimish2711 has quit IRC
10:23:58 *** nimish2711_ is now known as nimish2711
10:25:05 *** Mechtilde has quit IRC
10:28:00 *** jervin has joined #gnucash
10:30:39 *** jervin has quit IRC
10:32:48 *** kael has joined #gnucash
10:32:48 *** ChanServ sets mode: +v kael
11:09:13 <fell> .
11:15:09 *** oozer has joined #gnucash
11:15:18 *** fabior has joined #gnucash
11:16:24 *** guak has joined #gnucash
11:17:02 *** kael has quit IRC
11:30:36 *** warlord has quit IRC
11:30:50 *** warlord has joined #gnucash
11:30:50 *** gncbot sets mode: +o warlord
11:46:47 *** kael has joined #gnucash
11:46:48 *** ChanServ sets mode: +v kael
11:56:33 *** warlord has quit IRC
11:58:17 *** fabior has quit IRC
11:59:04 *** kael has quit IRC
12:01:50 *** warlord has joined #gnucash
12:01:51 *** gncbot sets mode: +o warlord
12:11:01 *** warlord has quit IRC
12:14:55 *** fabior has joined #gnucash
12:17:19 *** warlord has joined #gnucash
12:17:19 *** gncbot sets mode: +o warlord
12:27:03 *** warlord has quit IRC
12:28:51 *** warlord has joined #gnucash
12:28:51 *** gncbot sets mode: +o warlord
12:30:31 *** kael has joined #gnucash
12:30:32 *** ChanServ sets mode: +v kael
12:32:02 *** warlord has quit IRC
12:32:51 *** warlord has joined #gnucash
12:32:51 *** gncbot sets mode: +o warlord
12:34:39 *** nicoroumeau has joined #gnucash
12:35:30 *** Mechtilde has joined #gnucash
12:35:31 *** ChanServ sets mode: +v Mechtilde
12:38:04 *** nicoroumeau has quit IRC
12:39:54 *** nicoroumeau has joined #gnucash
12:55:29 *** fabior has quit IRC
12:55:52 *** kael has quit IRC
13:04:09 *** calvinct has joined #gnucash
13:11:57 *** jerryq has quit IRC
13:13:13 *** jerryq has joined #gnucash
13:25:13 *** jervin has joined #gnucash
13:36:33 *** fabior has joined #gnucash
13:43:21 *** calvinct has quit IRC
13:49:50 *** fabior has quit IRC
13:55:11 *** jerryq has quit IRC
13:55:22 *** jerryq has joined #gnucash
13:56:32 *** warlord has quit IRC
13:59:54 *** warlord has joined #gnucash
13:59:54 *** gncbot sets mode: +o warlord
14:14:49 *** nicoroumeau has quit IRC
14:17:58 *** nicoroumeau has joined #gnucash
14:23:40 *** nicoroumeau has quit IRC
14:24:56 *** ecdhe has quit IRC
14:27:51 *** ecdhe has joined #gnucash
14:37:33 *** frakturfreak has joined #gnucash
14:37:33 *** ChanServ sets mode: +v frakturfreak
14:42:16 *** nimish2711 has quit IRC
14:49:19 *** storyjesse has quit IRC
14:49:29 *** puck has quit IRC
14:49:31 <jralls> gjanssens: This is weird. After my changes yesterday if I open a Balance Sheet Report and set the report name, report title, and company name in chinese, it all works right. I save the book and quit GnuCash, all are written correctly in the gcm file correctly.
14:50:37 <jralls> Start up GnuCash and the Report Name and Company Name are good but the Report Title is converted to Latin1. Huh?
14:50:47 *** storyjesse has joined #gnucash
14:52:46 <jralls> If I save it as a saved report configuration and reload it after closing and restarting GnuCash it's restored correctly.
14:53:35 *** nicoroumeau has joined #gnucash
14:54:13 <fell> Then the bug seems to be in reading gcm
14:56:37 *** puck has joined #gnucash
14:59:18 <jralls> fell: Well.... The report options are stored as a single scheme string that's apparently passed to gnc-plugin-page-report.c.
15:02:49 *** storyjesse has quit IRC
15:06:03 *** frakturfreak has quit IRC
15:07:02 <gjanssens> Odd indeed... That usggests the report title is processed differently
15:07:13 *** frakturfreak has joined #gnucash
15:09:08 *** jervin has quit IRC
15:09:33 <jralls> I don't see how. The options string (with CRs added and extra spaces removed for clarity): https://gist.github.com/jralls/3c7a0420574be5d8b8e084c3f04a0d36
15:11:01 *** nicoroumeau has quit IRC
15:11:14 *** nicoroumeau has joined #gnucash
15:12:23 <fell> Isn't the title also used as page name?
15:12:55 *** nicoroumeau has quit IRC
15:14:48 <gjanssens> fell: no, that appears to be the "Report Name" rather than "Report Title"
15:15:16 <gjanssens> jralls: I don't see the "Report Name" option used in the html generated by the report, but only as tab name.
15:15:47 <gjanssens> Have you also tried to set the company name to something in Chinese and check how that survives the load from gcm file ?
15:16:14 <jralls> Yes, I think that's right. Yes, the company name is also in Chinese but that part seems not to be written to the gcm file.
15:16:14 <gjanssens> I suspect our parsing of the gcm file on windows is flawed.
15:16:41 <gjanssens> The gcm file is utf8
15:16:55 <gjanssens> But guile probably expects all strings to be in the system's locale
15:17:20 <gjanssens> I haven't dug into this at all, just a first guess
15:18:23 <gjanssens> For me the modified company name is written to the gcm file (on my linux box)
15:18:35 <jralls> The thing is that we're passing a single string to scm_c_eval_string() at gnc-plugin-page-report.c line 926. It has two Chinese options set, the first is read as Latin1, the second as UTF8.
15:19:35 <jralls> Ah, I didn't override the company name, it's getting it from options. Let me try that.
15:20:45 *** KevinDB has quit IRC
15:21:05 <jralls> Yes, that gets read as Latin1 too.
15:21:51 <gjanssens> I suspected as much
15:22:45 *** KevinDB has joined #gnucash
15:22:46 *** ChanServ sets mode: +v KevinDB
15:22:59 <gjanssens> Note that while report name is stored in the options I doubt it will be used to set the tab name. There's also a key "Page Name" in the gcm file (which is set to the report name while saving to scm) and I think that will be restored on loading from gcm
15:23:35 <gjanssens> If you open the options dialog for the garbled report, what does it show as values for the 3 options ?
15:23:44 <gjanssens> Are they latin1 there as well or proper chinese ?
15:24:20 <jralls> Report Name is UTF8, Report Title and Company Name are in Latin1.
15:25:37 <gjanssens> Still pretty odd...
15:26:36 <jralls> But maybe the report name is also filled from the PageName item instead of the Scheme value?
15:29:16 <gjanssens> jralls: I think so. In the same file there's also a function called gnc_plugin_page_report_name_changed (line 986) which is called whenever external code changes the tab title.
15:29:43 <gjanssens> I'm pretty sure the generic code to restore a tab from gcm does set that name at some point, which would trigger this function
15:29:56 <gjanssens> That in turn would set the "Report Name" guile option
15:30:10 <gjanssens> As this is in-code it remains as utf-8
15:31:49 <gjanssens> You could set a breakpoint in line 988 and check what was loaded initially from the gcm file before it gets overwritten to test this theory
15:33:25 <jralls> OK, But I have think I have a fix: convert the string to SCM with scm_from_utf8_string and pass that to scm_eval_string.
15:34:34 <gjanssens> That sounds good
15:35:55 *** tienne has joined #gnucash
15:36:07 <gjanssens> So besides being our date-time expert, you have now earned the title of data encoding/guile interoperability expert :)
15:38:46 <jralls> \o/! Do I get a badge? ;-)
15:39:39 <jralls> Hmm, gdb seems broken in my MSYS2 environment. I'll proceed with the build and try the debug on Mac.
15:39:40 <gjanssens> That would be fun :D
15:39:55 <gjanssens> (That referred to the badge thing)
15:47:08 *** Mechtilde has quit IRC
15:50:20 <jralls> Yes, it calls the function. Of course in MacOS the two values are the same so I can't tell if it got a bad value from the SchemeOption string, but I think that it's reasonable to assume that it would.
15:51:07 *** frakturfreak has quit IRC
15:52:24 *** frakturfreak has joined #gnucash
15:52:24 *** ChanServ sets mode: +v frakturfreak
16:02:05 *** nicoroumeau has joined #gnucash
16:05:05 <jralls> scm_from_utf8_string didn't work.
16:06:01 <gjanssens> :(
16:09:56 <warlord> :(
16:23:38 <jralls> Curious. I printed the option string before passing it to scm_from_utf8_string and it was already munged.
16:25:47 <gjanssens> Huh, how's that possible?
16:25:56 <gjanssens> Is it not utf-8 inside that file then ?
16:26:53 <jralls> Ah, right. Once munged it gets saved in munged form.
16:27:03 <gjanssens> Oh, phew
16:29:33 *** calvinct has joined #gnucash
16:30:01 <jralls> And with that sorted, scm_from_utf8_string *does* work.
16:31:44 <gjanssens> \o/
16:32:45 <gjanssens> So we'll have to inform users experiencing this issue they'll have to make a one time fix the garbled options after switching to the new gnucash release
16:32:58 <gjanssens> *to* the garbled options...
16:34:45 <gjanssens> jralls: something totally different
16:35:11 <gjanssens> I got a mail around April 20 from our wiki that you had made changes to the page User:lmat
16:35:23 <gjanssens> However there were no details and I don't see any history either
16:35:38 <gjanssens> So that makes me curious: what did you change ?
16:36:08 <jralls> I added him and chris to the auto-patrolled list so that I don't have to approve their posts.
16:36:19 *** calvinct has quit IRC
16:37:02 <gjanssens> Ah, ok
16:39:57 <fell> i was wondering, too
16:41:22 <jralls> Isn't there a better way to pass scheme functions around than scm_c_eval_string("gnc:function")? We seem to that a lot.
16:47:55 *** nicoroumeau has quit IRC
16:48:57 <gjanssens> Not that I know of
16:49:11 *** Agfarmer18 has joined #gnucash
16:49:39 <gjanssens> In most cases it's harmless though as we're just using it to convert a litteral function name into a scheme object
16:50:31 <gjanssens> That object will then later be used in the actual evaluation functions like scm_apply_x or scm_call_x
16:50:38 <gjanssens> (with x being a number)
16:51:04 <gjanssens> Only when using it to evaluate user-provided data this becomes tricky
16:52:03 <jralls> Oh, I understand what it's for. I just hate passing strings around, it's remarkably inefficient.
16:53:00 <gjanssens> The alternative is passing scm objects around, but in many cases we don't have them handy :(
16:53:10 <jralls> Speaking of user-provided data, your settings migration gets a basedir from g_get_home_dir() and then passes that as part of a string to scm_c_eval_string.
16:53:24 <gjanssens> *not* calling into guile would be more efficient :)
16:53:46 <jralls> Well, yeah, I hate that too. Sorry chris. ;-)
16:54:23 <gjanssens> That's probably another potential source of issues (failing option conversions)
16:55:22 <jralls> Yeah, I grepped for scm_c_eval_string, picked out the hits that aren't constants, and now I'm checking them.
16:56:17 *** frakturfreak has quit IRC
17:01:21 <jralls> Heh, in test-scm-query_string it calls scm_to_utf8_string and passes *that* to scm_c_eval_string. A bit mind-bending!
17:08:33 <gjanssens> :) Tests are supposed to push the limits, right ?
17:08:34 <jralls> gjanssens, warlord: gnc_gsettings and test-scm-query-string were the only other places where possibly non-ascii input got passed to scm_c_eval_string. Can you think of any other way that encoding can bite us?
17:09:12 <gjanssens> No
17:09:15 <jralls> Lol!
17:09:26 <jralls> (to pushing limits)
17:10:06 <gjanssens> (got that)
17:21:03 <gjanssens> jralls: I have begun the process of setting up the gnucash build env on my Win7 VM
17:21:12 <gjanssens> I'm taking the opportunity to proof-read the wiki
17:21:40 <gjanssens> And I get an issue on the very first command: help path\to\setup-mingw.ps1 fails
17:22:38 <jralls> ISTR that the powershell that comes with Win7 is too old but that you can upgrade it.
17:23:16 <gjanssens> https://imgur.com/a/dzQ2Hox
17:23:26 <gjanssens> Oh, maybe. I'll dig into that
17:23:42 <jralls> https://docs.microsoft.com/en-us/powershell/scripting/install/installing-windows-powershell?view=powershell-6
17:25:57 <gjanssens> What version do you have on your system ? Mine is 6.1
17:27:41 <jralls> 5.1.17763.316 on Win10.
17:28:02 <gjanssens> Hmm, I doubt I'm looking at the right version number then
17:28:28 <jralls> Tell powershell $PSVersionTable. It's the first entry.
17:28:42 *** tienne has quit IRC
17:29:51 <gjanssens> Ah, that's more realistic: PSVersion 2.0
17:30:13 <gjanssens> (First entry is CLRVersion, which is also at 2.0)
17:30:18 <gjanssens> BuildVersion is 6.1
17:30:23 <gjanssens> No idea what that means
17:30:53 <gjanssens> It's clearly been a while. I reported a bug for this myself :( https://bugs.gnucash.org/show_bug.cgi?id=787177
17:31:23 <gjanssens> (The only thing to do about that though is to update the wiki)
17:42:04 <jralls> Sorry, phone call...
17:45:40 <gjanssens> Np. It'll take more time here anyway. Windows 7 won't install .Net frameworks 4.5 (due to already having 4.7.2) and PowerShell won't install due to missing .Net 4.5
17:45:45 <gjanssens> To be continued later
17:45:49 <gjanssens> It's time for bed
17:48:34 *** gjanssens has quit IRC
17:53:51 *** Agfarmer18 has quit IRC
18:02:01 <jralls> chris: I think I've nailed down all of the transcoding problems from Guile2.2. Please get tomorrow's nightly and see if you can break it.
18:12:15 *** jerryq has quit IRC
18:39:25 *** Aussie_matt has joined #gnucash
18:58:47 *** raphaal has quit IRC
19:04:29 <fell> jralls, what is wrong with https://github.com/Gnucash/gnucash-docs/blob/maint/help/C/figures/Help_Pref_Business.png?
19:06:43 <fell> (PrtScrn->FullScreen instead of SelectedWindow)
19:13:33 <fell> I will fix it.
19:17:34 <fell> Prefs Online-Banking, too. Will check all
20:40:14 *** zp2133 has joined #gnucash
20:46:58 <fell> jralls, in commit 7f951fc you replaced somehow gnucash-docs/help/C/figures/Report_Screen.png by a totally different file.
20:47:44 *** storyjesse has joined #gnucash
20:48:51 <fell> Before it is an account report, after a txn report about investment after selling, which seems to belong to guide/ch_invest.
20:49:08 <fell> But I can not solve the puzzle. :-(
20:49:56 <fell> The name is also very strange and I can not find it in the text.
20:52:16 *** User_ has joined #gnucash
21:00:51 *** User_ has quit IRC
21:04:44 *** guak has quit IRC
21:26:50 *** jerryq has joined #gnucash
21:30:29 *** ArtGravity has quit IRC
21:32:43 *** zp2133 has quit IRC
21:52:37 *** storyjesse has quit IRC
21:56:29 <chris> jralls a cleaner approach to calling scheme may soemthing like https://gist.github.com/ncweinhold/9724254 although I don't quite know the nuance differences - avoids eval-string
22:05:17 *** nimish2711 has joined #gnucash
22:06:21 *** storyjesse has joined #gnucash
22:07:18 *** storyjesse has quit IRC
22:20:06 *** oozer has quit IRC