Re: [GNC] Recovering deleted transaction from log files

2020-02-24 Thread John Ralls
There's two sorts of logging. GnuCash emits varying levels of messages (error, 
warning, info, or debug) into the trace file 
(https://wiki.gnucash.org/wiki/Tracefile) depending on command-line arguments. 
The default is to emit only errors.

The other logging, the one that Roland is talking about, is transaction 
logging. This writes to a log file that GnuCash knows how to import with 
File>Import>Replay Gnucash .log file, writing an entry every time a transaction 
object is locked or unlocked for editing. It's not configurable. Scheduled 
Transaction templates aren't locked so they're not logged, but when the SX 
creates a transaction that will be logged. The only way to not log an edit 
would be code that doesn't call xaccTransBeginEdit/xaccTransCommitEdit and any 
code that doesn't do that risks also that its changes won't be saved, 
particularly in the SQL backends.

Regards,
John Ralls



> On Feb 24, 2020, at 3:23 AM, Greg Feneis  wrote:
> 
> I imagine logging is minimal by default to help keep GnuCash speedy.
> Unless the user increases verbosity via CLI when launching GnuCash.  Just a
> guess.
> 
> I'm also curious about controlling logging. I bet it's documented somewhere
> 
> Kind regards, Greg Feneis
> (Pixel 3)
> 
> 
> On Sat, Feb 22, 2020, 15:00 Roland Roberts  wrote:
> 
>> On 2/21/2020 11:54 PM, Roland Roberts wrote:
>>> [...]
>>> So... I figured the log file(s) between those two should have the
>>> missing transactions. But that file is nothing but a sequence of
>>> 
>>> = START
>>> = END
>>> 
>>> after the header.  Why wouldn't the log have my deleted transactions
>>> in it?
>> 
>> So I was able to track down the missing transaction. What had actually
>> happened was that I had apparently edited it (obviously in error) and
>> change the account on a payment to a credit card. That removed it's
>> reconciled state in the bank account from which the payment had been
>> made (naturally, it was no longer against that account). I did that the
>> painful way by unpacking the two gnucash files and doing diff, that
>> tracking through the diffs.
>> 
>> I'm still puzzled by the log file. I read through some of the gnucash
>> docs and realize that scheduled transactions are special beasts and that
>> those don't show up in the logs, but an edit like this I thought would.
>> My immediate problem is solved, but...I'd like to know what sort of
>> things the logs can help me with since it wasn't as useful as I expected
>> for this case.
>> 
>> roland
>> 
>> 
>> ___
>> gnucash-user mailing list
>> gnucash-user@gnucash.org
>> To update your subscription preferences or to unsubscribe:
>> https://lists.gnucash.org/mailman/listinfo/gnucash-user
>> If you are using Nabble or Gmane, please see
>> https://wiki.gnucash.org/wiki/Mailing_Lists for more information.
>> -
>> Please remember to CC this list on all your replies.
>> You can do this by using Reply-To-List or Reply-All.
>> 
> ___
> gnucash-user mailing list
> gnucash-user@gnucash.org
> To update your subscription preferences or to unsubscribe:
> https://lists.gnucash.org/mailman/listinfo/gnucash-user
> If you are using Nabble or Gmane, please see 
> https://wiki.gnucash.org/wiki/Mailing_Lists for more information.
> -
> Please remember to CC this list on all your replies.
> You can do this by using Reply-To-List or Reply-All.

___
gnucash-user mailing list
gnucash-user@gnucash.org
To update your subscription preferences or to unsubscribe:
https://lists.gnucash.org/mailman/listinfo/gnucash-user
If you are using Nabble or Gmane, please see 
https://wiki.gnucash.org/wiki/Mailing_Lists for more information.
-
Please remember to CC this list on all your replies.
You can do this by using Reply-To-List or Reply-All.


Re: [GNC] Recovering deleted transaction from log files

2020-02-24 Thread Greg Feneis
I imagine logging is minimal by default to help keep GnuCash speedy.
Unless the user increases verbosity via CLI when launching GnuCash.  Just a
guess.

I'm also curious about controlling logging. I bet it's documented somewhere

Kind regards, Greg Feneis
(Pixel 3)


On Sat, Feb 22, 2020, 15:00 Roland Roberts  wrote:

> On 2/21/2020 11:54 PM, Roland Roberts wrote:
> > [...]
> > So... I figured the log file(s) between those two should have the
> > missing transactions. But that file is nothing but a sequence of
> >
> > = START
> > = END
> >
> > after the header.  Why wouldn't the log have my deleted transactions
> > in it?
>
> So I was able to track down the missing transaction. What had actually
> happened was that I had apparently edited it (obviously in error) and
> change the account on a payment to a credit card. That removed it's
> reconciled state in the bank account from which the payment had been
> made (naturally, it was no longer against that account). I did that the
> painful way by unpacking the two gnucash files and doing diff, that
> tracking through the diffs.
>
> I'm still puzzled by the log file. I read through some of the gnucash
> docs and realize that scheduled transactions are special beasts and that
> those don't show up in the logs, but an edit like this I thought would.
> My immediate problem is solved, but...I'd like to know what sort of
> things the logs can help me with since it wasn't as useful as I expected
> for this case.
>
> roland
>
>
> ___
> gnucash-user mailing list
> gnucash-user@gnucash.org
> To update your subscription preferences or to unsubscribe:
> https://lists.gnucash.org/mailman/listinfo/gnucash-user
> If you are using Nabble or Gmane, please see
> https://wiki.gnucash.org/wiki/Mailing_Lists for more information.
> -
> Please remember to CC this list on all your replies.
> You can do this by using Reply-To-List or Reply-All.
>
___
gnucash-user mailing list
gnucash-user@gnucash.org
To update your subscription preferences or to unsubscribe:
https://lists.gnucash.org/mailman/listinfo/gnucash-user
If you are using Nabble or Gmane, please see 
https://wiki.gnucash.org/wiki/Mailing_Lists for more information.
-
Please remember to CC this list on all your replies.
You can do this by using Reply-To-List or Reply-All.


Re: [GNC] Recovering deleted transaction from log files

2020-02-22 Thread Roland Roberts

On 2/21/2020 11:54 PM, Roland Roberts wrote:

[...]
So... I figured the log file(s) between those two should have the 
missing transactions. But that file is nothing but a sequence of


= START
= END

after the header.  Why wouldn't the log have my deleted transactions 
in it?


So I was able to track down the missing transaction. What had actually 
happened was that I had apparently edited it (obviously in error) and 
change the account on a payment to a credit card. That removed it's 
reconciled state in the bank account from which the payment had been 
made (naturally, it was no longer against that account). I did that the 
painful way by unpacking the two gnucash files and doing diff, that 
tracking through the diffs.


I'm still puzzled by the log file. I read through some of the gnucash 
docs and realize that scheduled transactions are special beasts and that 
those don't show up in the logs, but an edit like this I thought would. 
My immediate problem is solved, but...I'd like to know what sort of 
things the logs can help me with since it wasn't as useful as I expected 
for this case.


roland


___
gnucash-user mailing list
gnucash-user@gnucash.org
To update your subscription preferences or to unsubscribe:
https://lists.gnucash.org/mailman/listinfo/gnucash-user
If you are using Nabble or Gmane, please see 
https://wiki.gnucash.org/wiki/Mailing_Lists for more information.
-
Please remember to CC this list on all your replies.
You can do this by using Reply-To-List or Reply-All.


[GNC] Recovering deleted transaction from log files

2020-02-21 Thread Roland Roberts
Somewhere in the last few days, I managed to delete one or more 
transactions that were reconciled. I'll blame it on sleep deprivation 
trying to get through my wife's business accounts and our personal ones, 
too


I went to my gnucash autosave files and began opening them until I found 
the last one with a good reconciliation and the first one with a bad 
reconciliation amount. Basically, I opened the account, then started the 
reconcile dialog and the latest one that showed an opening balance 
matching what I last has from reconciling was what I'm labeling as the 
last good one. The next autosave after that has a bad opening balance 
when I do the same thing.


So... I figured the log file(s) between those two should have the 
missing transactions. But that file is nothing but a sequence of


= START
= END

after the header.  Why wouldn't the log have my deleted transactions in it?

roland


___
gnucash-user mailing list
gnucash-user@gnucash.org
To update your subscription preferences or to unsubscribe:
https://lists.gnucash.org/mailman/listinfo/gnucash-user
If you are using Nabble or Gmane, please see 
https://wiki.gnucash.org/wiki/Mailing_Lists for more information.
-
Please remember to CC this list on all your replies.
You can do this by using Reply-To-List or Reply-All.