feat(chat): mark outgoing messages that fail to send
Outgoing echoes were recorded optimistically regardless of whether the broadcast was actually submitted. Now broadcastChatMemos / broadcastChatMemosLite return whether the send was submitted (false on immediate failures: not connected, no spendable z-address, or a lite send already in progress), and the echo records a ChatDelivery status (Sent / Failed). The Chat tab shows a "not sent" marker in the error color on failed messages. The status persists in the DB (backward- compatible: old rows deserialize as Sent). (A later async failure — an opid that fails after submission — still surfaces via the existing send-progress notification; only the submit gate is reflected here.) Also removes the now-unused chat_readonly_note string (the composer replaced the read-only footer). Test: delivery status round-trips through the DB. Verified: Linux + Windows build with chat ON, ctest 100%, hygiene clean. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -602,8 +602,8 @@ private:
|
||||
void provisionChatIdentityFromSecret(std::string secret);
|
||||
std::string chatReplyZaddr(); // a stable (persisted) wallet z-addr for chat
|
||||
std::string generateChatLocalId(const char* prefix, int numBytes) const; // unique echo id / cid
|
||||
void broadcastChatMemos(const chat::OutgoingChatMemos& memos); // full-node z_sendmany / lite
|
||||
void broadcastChatMemosLite(const chat::OutgoingChatMemos& memos); // lite two-recipient send
|
||||
bool broadcastChatMemos(const chat::OutgoingChatMemos& memos); // returns true if submitted
|
||||
bool broadcastChatMemosLite(const chat::OutgoingChatMemos& memos); // lite two-recipient send
|
||||
void ingestLiteChatMemos(const wallet::LiteWalletAppRefreshModel& model); // lite chat receive harvest
|
||||
// Lite first-run welcome prompt: dismissed for the session once the user picks an action.
|
||||
bool lite_firstrun_dismissed_ = false;
|
||||
|
||||
Reference in New Issue
Block a user