Skip to content

chore(deps): update utopia-php/migration to 2.1.0 and sdk-for-php to 30.2.2 - #14382

Merged
ChiragAgg5k merged 3 commits into
mainfrom
chore/migration-2.1
Oct 12, 2026
Merged

ChiragAgg5k merged 3 commits into
mainfrom
chore/migration-2.1

Conversation

@ChiragAgg5k

@ChiragAgg5k ChiragAgg5k commented Oct 12, 2026 •

Copy link
Copy Markdown
Member

Brings utopia-php/migration 2.1.0 into Appwrite, so the next self-hosted release migrates function intervals and the other settings migration was dropping. This is the release step from docs/releases.md (#14364).

Changes

Tests

The e2e tests in MigrationsBase:

  • New testAppwriteMigrationFunctionSettings: a fresh source project whose first function and first site share internal ID 1. The function has an hourly interval, 7-day retention, and one secret and one plain variable. The site has a secret variable. The test migrates both and checks that interval, retention and secret flags match, and that the function doesn't take the site's variable. It needs no deployment, so it runs quickly.
  • testAppwriteMigrationSite: the site now has a start command, 14-day retention and two scopes, and its variable is secret. All are asserted on the destination.
  • testAppwriteMigrationStorageFiles: the file is uploaded into albums/2026, and the destination's folder and key are asserted.
  • testAppwriteMigrationPolicies: also sets and asserts password strength, MFA factors, deny-free-email and membership userAccessedAt, and restores them afterwards.

Local run on a stack built from this branch, with migration 2.1.0 and SDK 30.2.2 in vendor. The four tests above plus the existing testAppwriteMigrationFunction pass: 312 assertions. The one deprecation is from the textalk/websocket test client.

With the variables fix reverted inside the worker, testAppwriteMigrationFunctionSettings fails with the site variable's 409, so it covers that regression.

utopia-php/migration#235 also has a separate end-to-end run with Console screenshots.

Closes #14365

…30.2.2

Migration 2.1.0 carries function intervals, site scopes, start commands and retention, function retention, variable secret flags, file folders and more auth policies. It reads sources through sdk-for-php 30.2, so appwrite/appwrite moves with it; the server's own SDK use (the migration worker's TablesDB scope probe, Query::limit, ID::unique) is unchanged in 30.2.2.
Function interval, retention and variable secret flags; site start command, retention, scopes and secret variable; file folder; password strength, MFA factors, deny-free-email and membership accessedAt policies.
@luxor-code-review

luxor-code-review Bot commented Oct 12, 2026 •

Copy link
Copy Markdown

Review complete. No issues found — approved ✅.


This PR upgrades the migration library pair (utopia-php/migration ^2.0.9 -> ^2.1.0 and appwrite/appwrite ^27.1 -> ^30.2.2, which are coupled requirements) and adds e2e coverage for the new resource attributes the upgraded migration transfers between Appwrite projects.

Files Change
composer.json Version bumps for utopia-php/migration and appwrite/appwrite, consistent with composer.lock.
tests/e2e/Services/Migrations/MigrationsBase.php New testAppwriteMigrationFunctionSettings test plus extensions to file, site, and policy migration tests asserting folder/key, interval/deploymentRetention, startCommand/scopes, secret flags, and policy toggle fidelity, with cleanup restoring defaults on both source and destination projects.

Reviewed commit: 651407c

@ghost

ghost commented Oct 12, 2026 •

Copy link
Copy Markdown

🟢 Tier S · Ready to merge

Updates utopia-php/migration to 2.1.0 and the Appwrite PHP SDK to 30.2.2, and expands migration e2e coverage for function and site settings, variables, file folders, and project policies. The function settings test now also exercises a fresh source project with both a function and a site and verifies that each resource keeps its own variables.

Latest changes: The newest commit extends the function settings migration test to create a function and site with variables in one fresh source project, then verifies both resources and their variables migrate independently.

Verdict New comments Fixed Still open
✅ Approved 0 1 0
📂 Walkthrough · 3
File Change
composer.json Raises the migration library and Appwrite PHP SDK dependency constraints.
composer.lock Locks the updated migration library, SDK, and resulting polyfill dependency.
tests/e2e/Services/Migrations/MigrationsBase.php Adds migration assertions for function/site settings, variables, storage folders, and project policies, including the shared-internal-ID function/site variable regression case.
✅ Fixed since the last review · 1
  • Cover the function/site variable collision regression · tests/e2e/Services/Migrations/MigrationsBase.php:2527

Reviewed the commits since 651407c · Details · Comment @hansi-codes review to re-run, or mention @hansi-codes with a question.

@ghost ghost left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Tier A · Looks good to merge. Summary

@github-actions

Copy link
Copy Markdown

Security rules

No new WARNING or ERROR findings from security rules.

32 existing findings tracked in .semgrep/baseline.json
  • php.appwrite.guest-write-without-abuse-limit (17)
  • php.appwrite.permissive-write-permission (8)
  • php.appwrite.secret-compare-timing (5)
  • php.appwrite.weak-secret-env-default (2)

Posted by Checks / Rules. Re-runs update this comment in place. Rule details and baseline: .semgrep/README.md.

A fresh source project gives its first function and first site the same internal ID, which is when the function list also returns the site's variables. The function settings test now migrates both, so copying the site's variable onto the function, and the 409 that follows for the site, fails it.
@github-actions

github-actions Bot commented Oct 12, 2026 •

Copy link
Copy Markdown

✨ Benchmark results

Comparing main (before) → chore/migration-2.1 (after).

Metric Before After Change
🚀 Requests/sec 201.14 214.89 🟢 +6.8%
⏱️ Latency P50 86.11 ms 82.62 ms ⚪ -4.1%
⏱️ Latency P95 206.02 ms 184.76 ms 🟢 -10.3%
Per-scenario breakdown & investigation details

Metrics below reflect the current branch (after). Δ P95 compares against the base.

Scenario P50 (ms) P95 (ms) Requests RPS Δ P95 (ms)
API total 82.62 184.76 13,680 214.89 -21.26
Account 150.89 271.38 720 12.08 -42.16
TablesDB 79.78 144.65 7,440 120.44 -22.67
Storage 75.91 162.3 3,600 59.61 -6.99
Functions 115.31 220.12 1,920 32.44 -12.85

Top API waits (after)

API request Max wait (ms)
storage.buckets.create 416.17
account.prefs.update 386.28
account.name.update 379.34
functions.create 354.77
functions.variables.create 352.24

@ghost ghost left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Tier S · Looks good to merge. Summary

@ChiragAgg5k
ChiragAgg5k merged commit ea1d6d6 into main Oct 12, 2026
65 checks passed
@ChiragAgg5k
ChiragAgg5k deleted the chore/migration-2.1 branch October 12, 2026 14:27
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.

Sync utopia-php/migration with each minor

1 participant