8000 fix: override template deployment type enum name by ChiragAgg5k · Pull Request #10848 · appwrite/appwrite · GitHub
[go: up one dir, main page]

Skip to content

Conversation

@ChiragAgg5k
Copy link
Member

No description provided.

@coderabbitai
Copy link
Contributor
coderabbitai bot commented Nov 20, 2025
📝 Walkthrough

Walkthrough

The change adds new enum-name mappings in the getRequestEnumName function inside src/Appwrite/SDK/Specification/Format.php. For services functions and sites, when the method is createTemplateDeployment and the parameter is type, the function now returns TemplateReferenceType. No public signatures were changed.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

  • Single, localized case additions in one mapping function with no structural changes
  • Verify the enum name TemplateReferenceType is defined and matches usages
  • Confirm the service (functions, sites), method (createTemplateDeployment), and parameter (type) combination is correct in related specs or tests (file: src/Appwrite/SDK/Specification/Format.php)

Pre-merge checks and finishing touches

❌ Failed checks (2 warnings)
Check name Status Explanation Resolution
Description check ⚠️ Warning No pull request description was provided by the author, making it impossible to evaluate whether the description relates to the changeset. Add a clear description explaining the purpose of the enum override, which services are affected, and why this change is necessary for template deployments.
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (1 passed)
Check name Status Explanation
Title check ✅ Passed The title 'fix: override template deployment type enum name' accurately and specifically describes the main change in the PR, which adds enum-name mapping for TemplateReferenceType in template deployment.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch template-type-enum-override

📜 Recent review details

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between fcce6f8 and a2463f8.

⛔ Files ignored due to path filters (8)
  • app/config/specs/open-api3-1.8.x-console.json is excluded by !app/config/specs/**
  • app/config/specs/open-api3-1.8.x-server.json is excluded by !app/config/specs/**
  • app/config/specs/open-api3-latest-console.json is excluded by !app/config/specs/**
  • app/config/specs/open-api3-latest-server.json is excluded by !app/config/specs/**
  • app/config/specs/swagger2-1.8.x-console.json is excluded by !app/config/specs/**
  • app/config/specs/swagger2-1.8.x-server.json is excluded by !app/config/specs/**
  • app/config/specs/swagger2-latest-console.json is excluded by !app/config/specs/**
  • app/config/specs/swagger2-latest-server.json is excluded by !app/config/specs/**
📒 Files selected for processing (1)
  • src/Appwrite/SDK/Specification/Format.php (2 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (18)
  • GitHub Check: E2E Service Test (Messaging)
  • GitHub Check: E2E Service Test (Migrations)
  • GitHub Check: E2E Service Test (Users)
  • GitHub Check: E2E Service Test (Databases/TablesDB)
  • GitHub Check: E2E Service Test (Storage)
  • GitHub Check: E2E Service Test (Teams)
  • GitHub Check: E2E Service Test (Sites)
  • GitHub Check: E2E Service Test (Tokens)
  • GitHub Check: E2E Service Test (Health)
  • GitHub Check: E2E Service Test (Databases/Legacy)
  • GitHub Check: E2E Service Test (GraphQL)
  • GitHub Check: E2E Service Test (Functions)
  • GitHub Check: E2E Service Test (Avatars)
  • GitHub Check: E2E Service Test (Account)
  • GitHub Check: E2E Service Test (Site Screenshots)
  • GitHub Check: E2E General Test
  • GitHub Check: Unit Test
  • GitHub Check: E2E Service Test (Dev Keys)
🔇 Additional comments (2)
src/Appwrite/SDK/Specification/Format.php (2)

298-303: LGTM - Consistent implementation across services.

The implementation for the sites service correctly mirrors the functions service implementation. This consistency ensures that template deployments are handled uniformly across both services.


269-274: LGTM - Implementation verified as correct.

The code follows the established pattern for enum type overrides in the SDK specification. Verification confirms:

  1. createTemplateDeployment method exists in both functions and sites services
  2. ✓ Pattern matches existing createVcsDeployment implementation exactly
  3. ✓ Type name "TemplateReferenceType" aligns with backend code using referenceType attributes
  4. ✓ Both services (functions/sites) have consistent implementations at lines 269-274 and 298-303

The enum type names in Format.php are SDK generation directives used by the SDK generator tool, not local PHP class definitions. This matches how VCSDeploymentType is already handled in the codebase.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link
github-actions bot commented Nov 20, 2025

Security Scan Results for PR

Docker Image Scan Results

Package Version Vulnerability Severity
imagemagick 7.1.2.3-r0 CVE-2025-62171 HIGH
imagemagick-c++ 7.1.2.3-r0 CVE-2025-62171 HIGH
imagemagick-dev 7.1.2.3-r0 CVE-2025-62171 HIGH
imagemagick-heic 7.1.2.3-r0 CVE-2025-62171 HIGH
imagemagick-jpeg 7.1.2.3-r0 CVE-2025-62171 HIGH
imagemagick-jxl 7.1.2.3-r0 CVE-2025-62171 HIGH
imagemagick-libs 7.1.2.3-r0 CVE-2025-62171 HIGH
imagemagick-openexr 7.1.2.3-r0 CVE-2025-62171 HIGH
imagemagick-webp 7.1.2.3-r0 CVE-2025-62171 HIGH
libecpg 17.6-r0 CVE-2025-12818 HIGH
libecpg-dev 17.6-r0 CVE-2025-12818 HIGH
libpq 17.6-r0 CVE-2025-12818 HIGH
libpq-dev 17.6-r0 CVE-2025-12818 HIGH
libxml2 2.13.8-r0 CVE-2025-49794 CRITICAL
libxml2 2.13.8-r0 CVE-2025-49796 CRITICAL
libxml2 2.13.8-r0 CVE-2025-49795 HIGH
libxml2 2.13.8-r0 CVE-2025-6021 HIGH
postgresql17-dev 17.6-r0 CVE-2025-12818 HIGH
github.com/containerd/containerd/v2 v2.0.2 CVE-2024-25621 HIGH
golang.org/x/crypto v0.31.0 CVE-2025-22869 HIGH
golang.org/x/oauth2 v0.24.0 CVE-2025-22868 HIGH
stdlib 1.22.10 CVE-2025-47907 HIGH
stdlib 1.22.10 CVE-2025-58183 HIGH
stdlib 1.22.10 CVE-2025-58186 HIGH
stdlib 1.22.10 CVE-2025-58187 HIGH
stdlib 1.22.10 CVE-2025-58188 HIGH

Source Code Scan Results

🎉 No vulnerabilities found!

@pkg-pr-new
Copy link
pkg-pr-new bot commented Nov 20, 2025

Open in StackBlitz

npm i https://pkg.pr.new/appwrite/appwrite/@appwrite.io/console@10848

commit: 50f26e8

@github-actions
Copy link
github-actions bot commented Nov 20, 2025

✨ Benchmark results

  • Requests per second: 1,312
  • Requests with 200 status code: 236,181
  • P99 latency: 0.151055623

⚡ Benchmark Comparison

Metric This PR Latest version
RPS 1,312 1,360
200 236,181 244,772
P99 0.151055623 0.15124557

@ChiragAgg5k ChiragAgg5k requested a review from Meldiron November 20, 2025 08:36
99E2
@Meldiron Meldiron merged commit 0fbdbb3 into 1.8.x Nov 20, 2025
42 checks passed
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.

3 participants

0