Replies: 1 comment 8 replies
-
When a destination sends an announce, it can optionally send arbitrary bytes of App Data, in the case of LXMF announces, this includes a Display Name and in newer versions of LXMF, an optional Stamp Cost. If you have an For
For any other announce type, you would have to know the format of the app data to know if it even includes a display name. This is entirely up to the developer :) Some announces/destinations may not include a display name at all. Here are the relevant lines in MeshChat for getting display names out of received announces: https://github.com/liamcottle/reticulum-meshchat/blob/59deac6d07d4d473f380cc8c246cab308cc104a1/meshchat.py#L3071 And here's an example that announces fruit names as the app data: Reticulum/Examples/Announce.py Line 95 in 9e7641d |
Beta Was this translation helpful? Give feedback.
-
I'm working on some python scripts projects for Reticulum and LXMF protocol, i managed to create peers, identity, send announce, send and receive messages over lxmf, but i can't do a simple (maybe) thing: extracting display_name !!
How can i achieve this?
I think i managed to get name hash with: RNS.prettyhexrep(my_lxmf_destination.name_hash)) ,
but how to see names in dehashed clear human readable format? i'm going crazy but didn't succeed in any way.
An AI told me that is not possible without a database containing correspondances between hash and name (a sort of address book with hash and correspinging names), is it right? and if that is correct...how to get the display name associated with the hash? save hash and name in a db from the announces?
I've checked the database.db created by Meshchat, but can't find display names there either.
If you can suggest a way to manage this problem with some example code i will be very happy!!
Thank you for anyone that will help! F.
Beta Was this translation helpful? Give feedback.
All reactions