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

[BUG] Inconsistent validations about the ledger #208

Closed
dhythm opened this issue Sep 14, 2021 · 2 comments · Fixed by #210
Closed

[BUG] Inconsistent validations about the ledger #208

dhythm opened this issue Sep 14, 2021 · 2 comments · Fixed by #210
Assignees
Labels
bug Something isn't working
Projects

Comments

@dhythm
Copy link

dhythm commented Sep 14, 2021

Describe the bug
An empty footer could be registered as a ledger template.
However, the ledger history API (GET /[domain}/[token_address}/history/{ledger_id}) will be failed to get the ledger with empty footer after the registration.

Expected behavior
An error doesn't happen and data should be returned.

Additional context
It could be better for the validation,

  • each header (ledger and details) doesn't allow empty input because there is the title / heading item on top of the header
  • each footer (ledger and details) allows empty input because the footer is isolated item.
@dhythm dhythm added the bug Something isn't working label Sep 14, 2021
@YoshihitoAso
Copy link
Member

YoshihitoAso commented Sep 16, 2021

Thank you for your feedback.

The inconsistency of the null constraint in the system is a bug, which we will fix.

Regarding your suggestion that the header should be non-null, this feature is built to be used for general purpose ledgers, so it is possible for a ledger to not have a header.
Therefore, we think it is right to design the header to allow null.

@YoshihitoAso YoshihitoAso added this to To do in v21.12.0 via automation Sep 16, 2021
@dhythm
Copy link
Author

dhythm commented Sep 16, 2021

Thank you for your reply and your idea is understood for me.
I will reconsider whether add the validation for the header at our frontend service or not.

Anyway, I'm waiting for fixing the bug. Thx 👍

@YoshihitoAso YoshihitoAso moved this from To do to In progress in v21.12.0 Sep 16, 2021
v21.12.0 automation moved this from In progress to Done Sep 17, 2021
YoshihitoAso added a commit that referenced this issue Sep 17, 2021
fix: inconsistent validations
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
No open projects
v21.12.0
  
Done
Development

Successfully merging a pull request may close this issue.

2 participants