GNOME Bugzilla – Bug 792833
User specifies source of 'num' field'; either transaction number or split action (requires at least GnuCash 2.5.0)
Last modified: 2018-06-30 00:03:38 UTC
Hi, I just updated from 2.6.18 to 2.7.3 and when opening my accounts, I got the following error: "User specifies source of 'num' field'; either transaction number or split action (requires at least GnuCash 2.5.0)"
Thank you for your report. Unfortunately I can't reproduce this, so we'll need more details. 1. Did you effectively set the "Use Split Action Field for Number" in File->Properties ? 2. What file format is your book ? XML, Sqlite, (My/Postgre)SQL ? 3. Is there anything in the gnucash trace file after you try to open your books in 2.7.3 ? http://wiki.gnucash.org/wiki/Tracefile explains where you can find the trace file.
Hi, 1) IIRC yes I selected that option at the creation of the file 2) SQLite 3) I'm not seeing anything suppositious at 1st sight (I'm using fr_BE.UTF-8 is that matters)
(In reply to Laurent Bigonville from comment #2) > Hi, > > 1) IIRC yes I selected that option at the creation of the file > > 2) SQLite Thanks, that's what I needed to reproduce. Next is to find a solution... For the other developers: it appears the feature flags are recursive slots. The first slot is named "features" and holds a reference to the child slot. The child slot is named "/Number Field Source" (not the initial /) and stores the description displayed to the user. I think the preceding slash is causing trouble in 2.7.x, while in 2.6.18 this is filtered out just fine. I suspect this bug got introduced in the code to flatten kvp.
Created attachment 367683 [details] Simple test file created with current maint HEAD gnucash The attached file can be used to reproduce this issue. I created this file from a gnucash build I generated from today's maint branch (so somewhere between 2.6.19 and 2.6.20 still to be released).
*** Bug 793626 has been marked as a duplicate of this bug. ***
Excellent detective work leads to a simple fix. Thanks, Geert! This problem has been fixed in the unstable development version. The fix will be available in the next major software release. You may need to upgrade your Linux distribution to obtain that newer version.
Hi, Are you sure it's fixed in 3.0? I get same error with that version
It should be fixed, however only for books that were never saved with gnucash 2.7.x. Did you try 2.7.x on a copy of your data file only or on your original file ? Note that since your book is in sqlite format gnucash will automatically save any changes, including updating feature codes. What does the following sqlite query return for your book: select * from slots where name like '%Number Field%' You will need to execute this query in some sqlite client on your book. Gnucash itself doesn't allow direct query input.
sqlite> select * from slots where name like '%Number Field%'; 1269|cf727f41e1484c8193b7a43835d2bcf4|/Number Field Source|4|0|User specifies source of 'num' field'; either transaction number or split action (requires at least GnuCash 2.5.0)||1970-01-01 00:00:00||0|1|
Thanks. That confirms your database was modified by one of the 2.7 test instances. The solution in this case depends on whether you have indeed enabled the option to swap transaction number and split action. If you do, change the name field to read features/Number Field Source Otherwise drop the '/Number Field Source' record. If you're unsure, you can drop the record anyway and reset the option in gnucash to your preference. The feature only affects presentation of the data, not the storage format. Does this fix it for you ?
OK it works for me here. But that's far from being user friendly, wouldn't potentially other people be impacted by this?
Glad that worked for you. As for the impact, it will only happen to users that opened their production data file with a beta version of gnucash instead of on a copy of it. I believe we did warn about that elaborately with each release.
GnuCash bug tracking has moved to a new Bugzilla host. This bug has been copied to https://bugs.gnucash.org/show_bug.cgi?id=792833. Please update any external references or bookmarks.