A Bluesky labeler that labels accounts hosted on PDSes operated by entities other than Bluesky PBC
3
fork

Configure Feed

Select the types of activity you want to include in your feed.

Improve new PDS discovery

gbl08ma 635b6509 cb634373

+8 -1
+8 -1
labeler.ts
··· 226 226 this.scheduleTask(async () => { 227 227 const did = uri as `did:${"plc" | "web"}:${string}`; 228 228 const pds = await this.crawler.identifyPDSofDID(did, true); 229 - await this.processSingleDID(pds, did); 229 + const maybeKnownPDS = await this.knownPDSStorage.getKnownPDS(pds); 230 + 231 + if (typeof maybeKnownPDS === "undefined") { 232 + console.log(`Crawling new PDS discovered when reprocessing labels for ${did}: ${pds}`); 233 + await this.processPDS(pds); 234 + } else { 235 + await this.processSingleDID(pds, did); 236 + } 230 237 totalProcessed++; 231 238 resolve(); 232 239 });