Skip to content

fix: map cloud SDK reference alias to 1.9.x#2952

Merged
ChiragAgg5k merged 3 commits intomainfrom
fix/cloud-version-alias-rust-tablesdb
May 1, 2026
Merged

fix: map cloud SDK reference alias to 1.9.x#2952
ChiragAgg5k merged 3 commits intomainfrom
fix/cloud-version-alias-rust-tablesdb

Conversation

@ChiragAgg5k
Copy link
Copy Markdown
Member

Summary

  • /docs/references/cloud/server-rust/* was rendering an empty endpoints page (e.g. tablesDB) while the version-pinned /1.9.x/server-rust/tablesDB page worked fine.
  • Root cause: +page.server.ts hardcoded the cloud alias to 1.8.x, but the Rust SDK was only added to @appwrite.io/specs in 1.9.x. The example loader iterates each method, builds a path like /node_modules/@appwrite.io/specs/examples/1.8.x/server-rust/examples/..., and continues on miss — for Rust under 1.8.x, every method missed (no server-rust/ directory exists in 1.8.x at all), so data.methods ended up empty and the page silently rendered with no endpoints. Other languages were unaffected because their example directories exist in both 1.8.x and 1.9.x.
  • Fix: bump the alias from 1.8.x to 1.9.x to match the version Cloud actually runs.

Test plan

  • Visit /docs/references/cloud/server-rust/tablesDB and confirm endpoints render
  • Visit /docs/references/cloud/server-nodejs/tablesDB and confirm no regression
  • Spot-check a couple of other cloud/<platform>/<service> references (e.g. cloud/server-python/databases, cloud/client-web/account) still render correctly
  • Confirm /docs/references/1.9.x/server-rust/tablesDB is still equivalent to the new cloud page

The cloud version alias was hardcoded to 1.8.x, but the Rust SDK was
only added in 1.9.x. As a result, /docs/references/cloud/server-rust/*
rendered an empty endpoints page because every method's example path
missed the glob and was skipped. Other languages had 1.8.x examples,
so the bug was Rust-only.
@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented May 1, 2026

Greptile Summary

This PR fixes the empty endpoints page for /docs/references/cloud/server-rust/* by replacing the hardcoded '1.8.x' cloud alias in +page.server.ts with the new latestVersion export from references.ts (allVersions[0], currently '1.9.x'). The platforms.svelte changes are purely cosmetic Tailwind class reordering.

Confidence Score: 5/5

Safe to merge — the fix is minimal, correct, and future-proof.

The core fix is straightforward: latestVersion resolves to '1.9.x' (verified in allVersions), which passes the existing versions.includes() guard. The platforms.svelte diff is pure formatting with no logic impact. No P1 or P0 issues found.

No files require special attention.

Important Files Changed

Filename Overview
src/lib/utils/references.ts Exports latestVersion = allVersions[0] ('1.9.x') as a single source of truth for the cloud alias.
src/routes/docs/references/[version]/[platform]/[service]/+page.server.ts Replaces hardcoded '1.8.x' cloud alias with latestVersion, so future Cloud version bumps auto-track the first entry in allVersions.
src/routes/(marketing)/(components)/platforms.svelte Pure formatting changes: Tailwind class reordering, whitespace normalization, and indentation fixes — no logic changes.

Reviews (3): Last reviewed commit: "chore: format platforms.svelte to unbloc..." | Re-trigger Greptile

Comment thread src/routes/docs/references/[version]/[platform]/[service]/+page.server.ts Outdated
Per review: hardcoding the alias would silently drift again on the
next Cloud bump. Export latestVersion (= allVersions[0]) from
references.ts and have the loader use it, so future version additions
to allVersions automatically update the cloud route.
Pre-existing formatting drift on main (introduced in 977683a) was
failing the format:check job. Pure prettier --write output —
Tailwind class ordering and re-indentation, no behavior change.
@ChiragAgg5k ChiragAgg5k merged commit 14fa3b0 into main May 1, 2026
6 checks passed
@ChiragAgg5k ChiragAgg5k deleted the fix/cloud-version-alias-rust-tablesdb branch May 1, 2026 05:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants