feat: v0.3.8 - Ping response shows hop count

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
ppfeiffer 2026-02-16 17:25:01 +01:00
parent e2f5e47ee9
commit a34162d428
3 changed files with 11 additions and 2 deletions

View file

@ -1,5 +1,9 @@
# 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
### Added
- Weather-Befehl zeigt Ortsnamen via Reverse-Geocoding (Nominatim)

View file

@ -1,4 +1,4 @@
version: "0.3.7"
version: "0.3.8"
bot:
name: "MeshDD-Bot"

View file

@ -262,7 +262,12 @@ class MeshBot:
response = None
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":
nodes = await self.db.get_all_nodes()