After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 721294 - Duplicate prompt for sub account creation
Duplicate prompt for sub account creation
Status: RESOLVED DUPLICATE of bug 777949
Product: GnuCash
Classification: Other
Component: Register
2.6.0
Other Windows
: Normal normal
: ---
Assigned To: gnucash-ui-maint
gnucash-ui-maint
: 725592 735230 738738 738753 754498 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2013-12-31 23:38 UTC by Art
Modified: 2018-06-29 23:23 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
GC_262_Bug_AccountAlreadyExists_140312.PNG (76.46 KB, image/png)
2014-03-13 03:20 UTC, Art
Details

Description Art 2013-12-31 23:38:28 UTC
My MO is to copy-paste the account, which in this case is a 2-level thing and I append ":thirdLevel" which emits a confirmation to create a sub-account prompt, twice. If I say yes to both, I get the, "Account already exists" message, so I just cancel the second prompt.
I just installed 2.6.0. The 2.4.13 version didn't manifest this behavior.
Please let me know if you need more details.
BTW, I have built GC before, but it's just too daunting under Windows 7, however, if someone were to do a 2-phase build, e.g., a Ming library and do all the high-level stuff in Visual Studio 2010, I'd love to debug it myself. (I'd volunteer to do some of the migration myself, but I have a day job.)
Comment 1 Richard Ullger 2014-01-03 00:44:07 UTC
I can confirm this behaviour on Linux also.
Comment 2 Alun Champion 2014-01-07 03:39:10 UTC
I can confirm this behaviour on the Mac also.
Comment 3 Brian Burns 2014-01-10 18:06:13 UTC
I also get this behavior on Windows.
Comment 4 Dave 2014-03-03 17:24:43 UTC
This occurs for me as well.  It appears isolated to the postgres backend, and happens across operating systems -- both Windows 7 and Linux (Ubuntu 13.10).
Comment 5 Geert Janssens 2014-03-07 17:43:41 UTC
Hmm, I can't immediately reproduce this on 2.6.2. Perhaps I'm trying the wrong steps as yours are fairly dense.

Can you write a more detailed step by step guide to reproduce the bug ?
Comment 6 Geert Janssens 2014-03-07 17:46:42 UTC
*** Bug 725592 has been marked as a duplicate of this bug. ***
Comment 7 Geert Janssens 2014-03-07 17:48:15 UTC
Tried again using the description in bug 725592, but it doesn't happen on my system (sqlite database).

Hmm, comment 4 suggests it's only happening on the postgresql database. I'll try that one.
Comment 8 Geert Janssens 2014-03-07 17:51:58 UTC
Can't even reproduce with a postgresql database :(

I'll need a more reliable way to reproduce before I can look into this...
Comment 9 Richard Ullger 2014-03-07 21:33:33 UTC
This no longer happens for me on 2.6.2, linux, xml.
Comment 10 Art 2014-03-07 22:03:42 UTC
I use MySQL database.
I had an expense account like, "Food:Groceries", then I would highlight the account and append, "Fruits", so my new account would look like,
  "Food:Groceries:Fruits"
and I'd get a prompt saying the account didn't exist and if I'd like to create it. I would click, "Yes" and GC would open a "Properties" dialog which I'd fill in and click "Ok" when done, but then it would prompt again to create the account.

At this point, I would just cancel the second prompt and everyone was happy.
I do this because it's easier than going to the account hierarchy and creating all accounts before using. I like to create them on the fly.

I'm pretty sure this also happens if I decide to organize my loans, e.g.,
I have an existing "Loans" account, then I edit the field in the transaction to show I made a payment to my new account, "Loans:VW2013" which induces the process to create a new account with the property panel and repeats the "Create new account" prompt after I click "Ok" on the first one.
Comment 11 Geert Janssens 2014-03-08 17:22:46 UTC
(In reply to comment #10)
> I use MySQL database.
> I had an expense account like, "Food:Groceries", then I would highlight the
> account and append, "Fruits", so my new account would look like,
>   "Food:Groceries:Fruits"
> and I'd get a prompt saying the account didn't exist and if I'd like to create
> it. I would click, "Yes" and GC would open a "Properties" dialog which I'd fill
> in and click "Ok" when done, but then it would prompt again to create the
> account.
> 
> At this point, I would just cancel the second prompt and everyone was happy.
> I do this because it's easier than going to the account hierarchy and creating
> all accounts before using. I like to create them on the fly.
> 
> I'm pretty sure this also happens if I decide to organize my loans, e.g.,
> I have an existing "Loans" account, then I edit the field in the transaction to
> show I made a payment to my new account, "Loans:VW2013" which induces the
> process to create a new account with the property panel and repeats the "Create
> new account" prompt after I click "Ok" on the first one.

Art, did you actually retry this yourself with gnucash 2.6.2 ? You seem to write from memory. But regardless, I still can't reproduce based on what you say here.

If you can reproduce, I'll need more details. Especially what you do between typing ":Fruits" and getting the prompt. I mean how do you leave the text entry field ? Do you hit the tab key, or an enter key, or an arrow key, or do you click with the mouse ? I tried most of them but none seem to get me into this situation.

You may also want to check the gnucash trace file for hints:
http://wiki.gnucash.org/wiki/Tracefile
Comment 12 Richard Ullger 2014-03-11 21:01:04 UTC
I experienced this issue again in 2.6.2 by entering a non existent account in the scheduled transaction editor. I was prompted to create the account. I clicked Yes and was immediately prompted to create the account a second time. I was creating a scheduled transaction by right-clicking on a transaction in an account register and selecting Schedule.

However, when I cancelled creating the scheduled transaction and repeated the process again, I was only prompted to create the account once.

Unfortunately, I couldn't reproduce this even by closing gnucash and starting again.
Comment 13 Art 2014-03-13 03:20:24 UTC
Created attachment 271681 [details]
GC_262_Bug_AccountAlreadyExists_140312.PNG

Screen capture mentioned in comment.
Comment 14 Art 2014-03-13 03:26:05 UTC
Geert, I just installed GC 2.6.2 built from rev 667b581+ on 2014-03-02 - from SF and the bug is still there.

This time, I entered "Food" and the sliding menu appears, so I hit the "End" key and typed, ":Test" and Ok.
I get a prompt,
 The account Food:Test does not exist. Would you like to create it?
To the "Yes" or "No" buttons, I click "Yes".

I get another prompt with the same dialog. Again, I click "Yes".
Now, I get the property dialog for "New Account - Food:Test".

I click, "Ok" and I get the same prompt again.

At this point, I get the, "There is already an account with that name." dialog box. So, I screen captured it and am attaching it to this entry.

You'll notice from my screen capture ("Snipping Tool" on Windows 7) that I'm running MySQL. MySQL runs under WampServer v2.2. (I sync the database on a Linux server and monitor it with Oracle's workbench, but is independent of GC.)
[I committed the attachment, but this comment didn't appear - I didn't realize this was a separate commitment process.]
Comment 15 Geert Janssens 2014-04-02 09:09:40 UTC
Ah, I finally managed to reproduce this. The key to this issue is that it only happens when adding a new account in split view mode. Richard's comment 12 lead me into the right direction as I could reproduce this in the scheduled transaction editor as well. Afterwards I noticed in Art's screen capture that he was creating the new account while the register was is split view mode. With my register set to split view I get the same behaviour.

Now only to figure out why this happens...
Comment 16 Alun Champion 2014-05-23 18:46:11 UTC
I'm running Gnucash 2.6.3 on OSX 10.9 (XML File backend) and the bug is still there.

To recreate:
Open the register of an account (e.g. Assets:Current:Bank A)
Create a transaction with a split going to a new account (e.g. Expenses:DoesNotExist).
When you hit tab or return you are prompted to create this account.
When you click yes, you get prompted a second time if you want to create this account.
When you say yes then the New Account details popup appears and you can fill in the details on the new account.
When you hit Ok, you are warned that the account already exists and then you return to the register.

I now just hit No on the second prompt to create the account and this avoids the warning at the end but still creates the account.
Comment 17 Geert Janssens 2014-09-22 16:34:33 UTC
*** Bug 735230 has been marked as a duplicate of this bug. ***
Comment 18 Mike Evans 2014-10-18 08:44:56 UTC
*** Bug 738738 has been marked as a duplicate of this bug. ***
Comment 19 Mike Evans 2014-10-18 10:18:12 UTC
*** Bug 738753 has been marked as a duplicate of this bug. ***
Comment 20 Geert Janssens 2015-09-12 15:02:20 UTC
*** Bug 754498 has been marked as a duplicate of this bug. ***
Comment 21 Wm 2016-12-29 20:39:24 UTC
It may not be clear from the above but I don't think the backend is significant as I get it with XML too.
Comment 22 Wm 2016-12-29 20:42:03 UTC
Sorry, point being Component SQL isn't appropriate now, more like Register, I think
Comment 23 John Ralls 2016-12-29 20:49:51 UTC
Agreed, and so changed.
Comment 24 Kenneth Ballard 2017-01-03 01:06:27 UTC
I am still able to reproduce this issue with 2.6.15 on Windows 10. Expected workflow at end.

* * *

1. Create transaction with several splits
2. On last split to enter, enter sub-account name that doesn't exist. Press Tab. "The account [account name] does not exist. Would you like to create it?"
3. Click No. Focus is returned to Transfer field.
4. Press Tab. "The account [account name] does not exist. Would you like to create it?"
5. Click Yes. "The account [account name] does not exist. Would you like to create it?"
6. Click No. Prompt is dismissed. "New Account - [account name]"
7. Click Cancel. Account editor dismissed. "The account [account name] does not exist. Would you like to create it?"
8. Click No. Prompt dismissed. Focus returned to Transfer field.
9. Press Tab. "The account [account name] does not exist. Would you like to create it?"
10. Click Yes. "The account [account name] does not exist. Would you like to create it?"
11. Click Yes. "New Account - [account name]"
12. Click OK. "New Account - [account name]"
13. Click OK. "There is already an account with that name".
14. Click Close. Focus returned to "New Account".
15. Click Cancel. Focus returned to Transfer field.
16. Click Tab. Account name accepted.

Expected: when the user clicks Yes on the prompt, the New Account dialog is displayed instead of the user being asked again if they want to create the account.

Currently the Expected result presents only when no additional splits to the transaction are entered when the new account is to be created:

1. Create transaction with no splits. Enter [account name] in the Transfer field. Press Tab. "The account [account name] does not exist. Would you like to create it?"
2. Click Yes. "New Account - [account name]".
3. Click Cancel. Focus returned to Transfer field.

* * *

1. Create transaction with several splits
2. On last split to enter, enter sub-account name that doesn't exist. Press Tab. "The account [account name] does not exist. Would you like to create it?"
3. Click Yes. "The account [account name] does not exist. Would you like to create it?"
4. Click Yes. "New Account - [account name]"
5. Click Cancel. "New Account - [account name]"
6. Click Cancel. "The account [account name] does not exist. Would you like to create it?"
7. Click Yes. "New Account - [account name]"
8. Click Cancel. Focus returned to Transfer field.

Expected result: again the user is to be prompted only once. The user also should not be prompted after clicking Cancel in the "New Account" dialog. Given the observations above, correcting such that the user is only prompted once will likely prevent the user from being prompted after pressing Cancel in the "New Account" dialog.

* * * * *

Expected workflow:

1. Create transaction with several splits
2. On last split to enter, enter sub-account name that doesn't exist. Press Tab. "The account [account name] does not exist. Would you like to create it?"
3. Click No. Focus is returned to Transfer field.
4. Press Tab. "The account [account name] does not exist. Would you like to create it?"
5. Click Yes. "New Account - [account name]".
6. Click Cancel. Account editor dismissed. Focus returned to Transfer field.
7. Press Tab. "The account [account name] does not exist. Would you like to create it?"
8. Click Yes. "New Account - [account name]".
9. Enter details and click OK. Account editor is dismissed. Account name accepted. Focus moves to DR field.
Comment 25 Geert Janssens 2017-03-11 11:25:41 UTC
Thanks for taking the time to report this.

This issue has been reported in the more recent bug 777949 as well and just got fixed. So all that is left to do is to mark this one as a duplicate.

The fix should go into 2.6.16 to be released soon. Should you still experience this issue, feel free to reopen.

*** This bug has been marked as a duplicate of bug 777949 ***
Comment 26 John Ralls 2018-06-29 23:23:11 UTC
GnuCash bug tracking has moved to a new Bugzilla host. This bug has been copied to https://bugs.gnucash.org/show_bug.cgi?id=721294. Please update any external references or bookmarks.