From 0700ccabaa6bbeb01ba147759bff93b0123646ba Mon Sep 17 00:00:00 2001
From: robk-tahoe <robk-tahoe@allmydata.com>
Date: Thu, 31 Jan 2008 19:11:31 -0700
Subject: [PATCH] stats_gatherer: reject "<unauth>" as a tubid, to avoid
 screwing up the data.

---
 src/allmydata/stats.py | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/allmydata/stats.py b/src/allmydata/stats.py
index fd6d4b27..dbdaf79e 100644
--- a/src/allmydata/stats.py
+++ b/src/allmydata/stats.py
@@ -120,6 +120,10 @@ class StatsGatherer(foolscap.Referenceable, service.MultiService):
 
     def remote_provide(self, provider, nickname):
         tubid = self.get_tubid(provider)
+        if tubid == '<unauth>':
+            print "WARNING: failed to get tubid for %s (%s)" % (provider, nickname)
+            # don't add to clients to poll (polluting data) don't care about disconnect
+            return
         self.clients[tubid] = provider
         self.nicknames[tubid] = nickname
         provider.notifyOnDisconnect(self.lost_client, tubid)
-- 
2.45.2