feat: v0.3.8 - Ping response shows hop count
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
e2f5e47ee9
commit
a34162d428
|
|
@ -1,5 +1,9 @@
|
||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## [0.3.8] - 2026-02-16
|
||||||
|
### Changed
|
||||||
|
- Ping-Antwort zeigt Hop-Anzahl des anfragenden Nodes (z.B. "Pong ueber 2 Hops!")
|
||||||
|
|
||||||
## [0.3.7] - 2026-02-16
|
## [0.3.7] - 2026-02-16
|
||||||
### Added
|
### Added
|
||||||
- Weather-Befehl zeigt Ortsnamen via Reverse-Geocoding (Nominatim)
|
- Weather-Befehl zeigt Ortsnamen via Reverse-Geocoding (Nominatim)
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
version: "0.3.7"
|
version: "0.3.8"
|
||||||
|
|
||||||
bot:
|
bot:
|
||||||
name: "MeshDD-Bot"
|
name: "MeshDD-Bot"
|
||||||
|
|
|
||||||
|
|
@ -262,7 +262,12 @@ class MeshBot:
|
||||||
response = None
|
response = None
|
||||||
|
|
||||||
if cmd == f"{prefix}ping":
|
if cmd == f"{prefix}ping":
|
||||||
response = "🏓 Pong!"
|
hops_str = ""
|
||||||
|
if from_id:
|
||||||
|
node = await self.db.get_node(from_id)
|
||||||
|
if node and node.get("hop_count") is not None:
|
||||||
|
hops_str = f" ueber {node['hop_count']} Hops"
|
||||||
|
response = f"🏓 Pong{hops_str}!"
|
||||||
|
|
||||||
elif cmd == f"{prefix}nodes":
|
elif cmd == f"{prefix}nodes":
|
||||||
nodes = await self.db.get_all_nodes()
|
nodes = await self.db.get_all_nodes()
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue