commit 78f5e299f109cf6742fc4c31b9012b755d5cde93
parent 491bef5fe8ebdc5ccb8ad531a36e74b85128564c
Author: Antoine A <>
Date: Mon, 18 Nov 2024 15:44:37 +0100
new ec and better kotlin codegen
Diffstat:
4 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/gnu-taler-error-codes/Makefile b/gnu-taler-error-codes/Makefile
@@ -56,8 +56,8 @@ taler_error_codes.ts.tmp: combined.tmp ts.template
taler_error_codes.ts: ts.header taler_error_codes.ts.tmp ts.footer
cat $^ | sed -e "s/= 0000/= 0/" -e "s/= 000/= /" -e "s/= 00/= /" > $@
-taler_error_codes.kt.tmp: combined.tmp kt.template
- ../format.sh kt.template < combined.tmp > $@
+taler_error_codes.kt.tmp: combined-escaped.tmp kt.template
+ ../format.sh kt.template < combined-escaped.tmp > $@
taler_error_codes.kt: kt.header taler_error_codes.kt.tmp kt.footer
cat $^ | sed -e "s/(0000)/(0)/" -e "s/(000/(/" -e "s/(00/(/" > $@
diff --git a/gnu-taler-error-codes/kt.header b/gnu-taler-error-codes/kt.header
@@ -22,4 +22,4 @@
*/
package tech.libeufin.common
-enum class TalerErrorCode(val code: Int) {
+enum class TalerErrorCode(val code: Int, val status: Int, val description: String) {
diff --git a/gnu-taler-error-codes/kt.template b/gnu-taler-error-codes/kt.template
@@ -1,8 +1,3 @@
-
- /**
- * {{Description}}
- * Returned with an HTTP status code of #MHD_HTTP_{{HttpStatus_Identifier}} ({{HttpStatus_Value}}).
- * (A value of 0 indicates that the error is generated client-side).
- */
- {{Name}}({{Value}}),
+ /** {{Description}} */
+ {{Name}}({{Value}}, {{HttpStatus_Value}}, "{{Description}}"),
diff --git a/gnu-taler-error-codes/registry.rec b/gnu-taler-error-codes/registry.rec
@@ -2588,6 +2588,11 @@ Name: BANK_PASSWORD_TOO_LONG
Description: Provided password is too long.
HttpStatus: 409
+Value: 5152
+Name: BANK_ACCOUNT_LOCKED
+Description: Bank account is locked and cannot authenticate using his password.
+HttpStatus: 403
+
# 6000 - 6999: Reserved for sync
# 6000 - 6099: Reserved for SYNC_GENERIC