Good thought - but the problem still occurs even if the share count and price are non-0. (The example transaction I've described is a simple reduction in the cost base of the asset without changing the number of shares held. But I think that is not directly relevant to the problem and probably the example I described more complex than it needed to be.)
Chris On Thu, 6 Oct 2022 at 09:45, R Losey <rlo...@gmail.com> wrote: > Perhaps I'm missing something, but if there is a transaction that has a > cost of 5000, and you have shares with a price of 0, that may be causing it > to think there is an imbalance, and thus the transactions get added? > > On Wed, Oct 5, 2022 at 7:09 AM Chris Grinton <cgrin...@gmail.com> wrote: > >> Hi GnuCashers, >> >> I have a strange situation where a transaction is automagically (and >> unexpectedly) getting splits added to it against the "Orphan-<currency>" >> and "Imbalance-<currency>" accounts when my GnuCash data file is closed >> and >> reopened. I can't work out why these splits are getting added, and would >> love any insights that people might have on how to stop it from happening. >> >> The unexpected behavior here appears to be somehow related to having >> trading accounts enabled, and a consequence of changing the namespace of a >> security. >> >> Here are steps I do to reproduce this problem: >> >> 1. Create a transaction as follows: >> Expenses:Realised capital losses DR 5000 >> Assets:Stock account CR >> 5000 (with shares & price = 0) >> >> This appears in GnuCash as per the following screenshot: >> >> [image: image.png] >> >> No change occurs to this transaction as long as I keep the GnuCash file >> open. >> >> 2. Edit the UNLISTED:ACME security, and change its namespace. For example, >> change the namespace from "UNLISTED" to "UNLISTED2". >> >> 3. Open a different GnuCash file (or close GnuCash), and then open the >> original file again. The act of opening the file appears to cause the >> transaction to be updated with additional splits to read as follows: >> >> Expenses:Realised capital losses DR 5000 >> * Orphan-AUD DR 5000* >> Assets:Stock account CR >> 5000 (with shares & price = 0) >> * Imbalance-AUD CR >> 5000* >> >> Here's a screenshot showing this: >> [image: image.png] >> >> 4. If I delete the Orphan & Imbalance splits, they continue to reappear >> every time I reopen the GnuCash file. >> >> I have not seen this behavior occurring for securities that have not had a >> namespace change, but is reliably reproducible for securities that have >> had >> a namespace change. >> >> I'm using GnuCash 4.8 on Windows with a SQLite data file. >> >> Thoughts? >> >> Thanks, >> Chris >> _______________________________________________ >> gnucash-user mailing list >> gnucash-user@gnucash.org >> To update your subscription preferences or to unsubscribe: >> https://lists.gnucash.org/mailman/listinfo/gnucash-user >> ----- >> Please remember to CC this list on all your replies. >> You can do this by using Reply-To-List or Reply-All. >> > > > -- > _________________________________ > Richard Losey > rlo...@gmail.com > Micah 6:8 > _______________________________________________ gnucash-user mailing list gnucash-user@gnucash.org To update your subscription preferences or to unsubscribe: https://lists.gnucash.org/mailman/listinfo/gnucash-user ----- Please remember to CC this list on all your replies. You can do this by using Reply-To-List or Reply-All.