]> git.aero2k.de Git - urlbot-v3.git/commit
Fix cross-bot infinite reply loop: honor the existing other_bots config
authorThorsten <mail@aero2k.de>
Sat, 18 Jul 2026 09:42:59 +0000 (11:42 +0200)
committerThorsten <mail@aero2k.de>
Sat, 18 Jul 2026 09:42:59 +0000 (11:42 +0200)
commitb0a37bb60b2d184611ed759b5fd6406210d88c17
tree72238b6012a6c60543a0c2c3af00c4f46735d521
parent5b012a51b7ac36e3143fe196c48664a0ab51a865
Fix cross-bot infinite reply loop: honor the existing other_bots config

muc_message() only ever ignored the bot's own nick. With multiple sibling
bot instances (urlbug, pibug, urlbrot) in the same room, each correctly
ignores itself but happily reacts to the others' replies - discovered
live when a smoke-test message containing a CVE id caused
SecurityTracker's URL reply to be picked up by the other bot's
URLResolver, whose title-scrape reply contained the same CVE id, causing
SecurityTracker to fire again, forever, across both bots, hammering
security-tracker.debian.org indefinitely until manually restarted.

persistent_config.ini.spec already had an `other_bots` key seemingly
designed for exactly this, but nothing in the codebase ever read it. Wired
it into muc_message()'s existing self-nick check. Populating the actual
other_bots list per host is a separate, per-deployment config change (not
committed here, since persistent_config.ini is gitignored per-host state).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
src/distbot/bot/bot.py
tests/test_unit/test_muc_message.py [new file with mode: 0644]