From 33660eadc6f2c6684d1a62247652b4dbf99a97f8 Mon Sep 17 00:00:00 2001 From: Bronek Kozicki Date: Wed, 26 Mar 2025 19:43:35 +0000 Subject: [PATCH] Add comment on tecNO_ENTRY vs tecOBJECT_NOT_FOUND --- include/xrpl/protocol/TER.h | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/include/xrpl/protocol/TER.h b/include/xrpl/protocol/TER.h index 81da933443..6a20f76ea3 100644 --- a/include/xrpl/protocol/TER.h +++ b/include/xrpl/protocol/TER.h @@ -265,6 +265,17 @@ enum TECcodes : TERUnderlyingType { // Otherwise, treated as terRETRY. // // DO NOT CHANGE THESE NUMBERS: They appear in ledger meta data. + // + // Note: + // tecNO_ENTRY is often used interchangeably with tecOBJECT_NOT_FOUND. + // While there does not seem to be a clear rule which to use when, the + // following guidance will help to keep errors consistent with the + // majority of (but not all) transaction types: + // - tecNO_ENTRY : cannot find the primary ledger object on which the + // transaction is being attempted + // - tecOBJECT_NOT_FOUND : cannot find the additional object(s) needed to + // complete the transaction + tecCLAIM = 100, tecPATH_PARTIAL = 101, tecUNFUNDED_ADD = 102, // Unused legacy code