Skip to content

Sitemap: AI models missing on dev and prod (numeric ids filtered out) #455

Closed

Description

@saqibmanan

What: every aimodels-N.xml child sitemap serves an empty <urlset>, on prod as well as dev. Prod lists aimodels-1.xml with 0 urls, while the prod backend has 15 public, active AI models.
Why it matters: no AI model pages are in the sitemap, so search engines aren't pointed to them.
Evidence: isEntityItem in app/sitemap/[entityPage]/route.ts (added in d750e88, 2026-08-31) keeps only string ids, but the API returns AI model ids as numbers: {"id": 44}.
Fix: #495 accepts string | number ids. Tested locally against the prod backend: 0 → 15 urls.
Earlier diagnosis was wrong: this issue was first put down to dev pagination and closed as not planned. Pagination isn't involved.

Activity

  1. added theissue type on Sep 9, 2026
  2. saqibmanan commented on Sep 9, 2026

    @saqibmanan
    ContributorAuthor

    Closing: SEO is not required on dev, so the empty aimodels sitemaps have no impact there. Prod is unaffected today — it serves 15 aimodels urls correctly.

    Recording the latent risk before closing, since prod is safe by accident rather than by design: this failure only appears where the sitemap is paginated. Prod is unpaginated solely because FEATURE_SITEMAP_ITEMS_PER_PAGE never reaches the EC2 runtime (same GH-Actions-var-vs-EC2-.env disconnect as FEATURE_SITEMAPS) and falls back to the 1000 default. That var is already set to 5 in prod, so whenever the propagation bug is fixed, prod paginates at 5/page and would hit this immediately. Prod would also paginate naturally at >1000 datasets (currently 234).

    Reopen if prod sitemaps ever start paginating.

    Test side: test_sitemap_aimodels_count_matches_backend in CivicDataSpace-test is marked xfail(strict=True) pointing at this issue, so it will report XPASS the moment the behaviour changes.

  3. changed the title [-]dev sitemap: aimodels child sitemaps serve 0 urls while index advertises 5 pages[/-] [+]Sitemap: AI models missing on dev and prod (numeric ids filtered out)[/+] on Oct 7, 2026
  4. saqibmanan commented on Oct 7, 2026

    @saqibmanan
    ContributorAuthor

    Reopening: the earlier diagnosis was wrong. Prod is affected too, and the cause is the string-only id filter, not pagination. Fix in #495.

  5. saqibmanan commented on Oct 7, 2026

    @saqibmanan
    ContributorAuthor

    #495 merged and deployed to dev 2026-10-07. Dev's sitemap is now off (#493), so the fix can only be confirmed on prod. Waiting for the next dev → main deploy; CivicDataSpace-test's prod aimodels count check starts running on its own once prod serves it.

  6. saqibmanan commented on Oct 9, 2026

    @saqibmanan
    ContributorAuthor

    On prod since the 2026-10-09 release (#500, 92cd5219): https://civicdataspace.in/sitemap/aimodels-1.xml lists 15 URLs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions