Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No input validation #17

Closed
slaxor opened this issue Mar 2, 2019 · 1 comment
Closed

No input validation #17

slaxor opened this issue Mar 2, 2019 · 1 comment

Comments

@slaxor
Copy link

slaxor commented Mar 2, 2019

I created a transaction with no values. after submitting the file was broken because it had an entry with empty amounts.
Offending entry:

-----------8<-----------8<-----------8<-----------8<-----------8<-----------
2019/02/13 jkljlkjl
    Konto
    cash
    bar
----------->8----------->8----------->8----------->8----------->8-----------

This left the entire app broken, there was no (obvious) way to fix this in the webui.
Error message:

-----------8<-----------8<-----------8<-----------8<-----------8<-----------
ledger.dat:18: Unable to balance transaction, more than one account change empty)
----------->8----------->8----------->8----------->8----------->8-----------

How it should be

Either valildate entries before writing or parse broken entries and let me open the form again.
Deleting or ignoring would not be acceptable because the bookkeeping would not be trustworthy anymore

@howeyc
Copy link
Owner

howeyc commented Mar 2, 2019

You're right, there's no way to fix in webui.

I usually edit the ledger with a text editor, and use the webui for view and reports mostly.

I'll look into validating the transaction in the webui before appending to the file.

@howeyc howeyc closed this as completed in 0208094 Mar 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants