simple list of pds servers with open registration

Show dash for unknown software instead of mislabeling as Bluesky PDS

+30 -17
+30 -17
backend/routes/pages.ts
··· 91 91 // Version check: compare against the server's own software latest version 92 92 // Extract clean semver from strings like "millipds v0.0.5.dev17+..." 93 93 const softwareId = detectSoftwareId(s, versionToSoftware); 94 - const expectedVersion = latestVersions[softwareId]; 95 - if (!expectedVersion) { 96 - // Link-only software with no tracked version: benefit of the doubt 94 + if (!softwareId) { 95 + // Unknown software: can't fairly compare, benefit of the doubt 97 96 check(true, "Latest version"); 98 97 } else { 99 - const cleanVersion = extractSemver(s.version); 100 - check(cleanVersion === expectedVersion, "Latest version"); 98 + const expectedVersion = latestVersions[softwareId]; 99 + if (!expectedVersion) { 100 + // Link-only software with no tracked version: benefit of the doubt 101 + check(true, "Latest version"); 102 + } else { 103 + const cleanVersion = extractSemver(s.version); 104 + check(cleanVersion === expectedVersion, "Latest version"); 105 + } 101 106 } 102 107 103 108 return { score, breakdown: signals.join("\n") }; ··· 335 340 336 341 // Determine version badge class based on per-software comparison 337 342 const softwareId = detectSoftwareId(s, versionToSoftware); 338 - const expectedVersion = latestVersions[softwareId]; 339 343 const cleanVersion = extractSemver(s.version); 340 344 const versionText = cleanVersion || "unknown"; 341 345 let versionClass = "version-outdated"; 342 - if (!expectedVersion || cleanVersion === expectedVersion) { 346 + if (!softwareId) { 347 + // Unknown software: no comparison possible 343 348 versionClass = "version-current"; 349 + } else { 350 + const expectedVersion = latestVersions[softwareId]; 351 + if (!expectedVersion || cleanVersion === expectedVersion) { 352 + versionClass = "version-current"; 353 + } 344 354 } 345 355 346 356 // Software cell: linked name to project URL 347 - const config = getSoftwareConfig(softwareId); 348 - const softwareHtml = config 349 - ? `<a class="software-link" href="${ 350 - esc(config.projectUrl) 351 - }" target="_blank" rel="noopener">${esc(config.displayName)}</a>` 352 - : esc(softwareId); 357 + let softwareHtml = "&mdash;"; 358 + if (softwareId) { 359 + const config = getSoftwareConfig(softwareId); 360 + softwareHtml = config 361 + ? `<a class="software-link" href="${ 362 + esc(config.projectUrl) 363 + }" target="_blank" rel="noopener">${esc(config.displayName)}</a>` 364 + : esc(softwareId); 365 + } 353 366 354 367 const users = s.user_count != null 355 368 ? (s.user_count >= 1000 ? "1000+" : String(s.user_count)) ··· 404 417 { prefix: "0.8.", softwareId: "cocoon" }, 405 418 ]; 406 419 407 - /** Detect software from DB field, version-to-software map, or version string */ 420 + /** Detect software from DB field, version-to-software map, or version string. Returns null if unknown. */ 408 421 function detectSoftwareId( 409 422 server: PdsServer, 410 423 versionToSoftware: VersionSoftwareMap, 411 - ): string { 424 + ): string | null { 412 425 // 1. Already detected by cron 413 426 if (server.pds_software) return server.pds_software; 414 - if (!server.version) return "bluesky-pds"; 427 + if (!server.version) return null; 415 428 416 429 // 2. Exact version match against known versions from all tracked software 417 430 if (versionToSoftware[server.version]) { ··· 441 454 } 442 455 } 443 456 444 - return "bluesky-pds"; 457 + return null; 445 458 } 446 459 447 460 function esc(str: string): string {