Commit graph

7015 commits

Author SHA1 Message Date
eldadfux
4bf3c72196 fix: allow users to update phone number to empty without causing duplicate errors 2026-03-11 06:25:08 +01:00
Luke B. Silver
e5f0bc2df6
Merge pull request #11457 from appwrite/fix-migration-errors
Fix migration errors
2026-03-06 17:20:39 +00:00
Chirag Aggarwal
8b026d3459 perf: optimize updateDocument() calls to use sparse documents
Optimize updateDocument() calls across the codebase to pass only changed
attributes as sparse Document objects rather than full documents. This is
more efficient because updateDocument() internally performs array_merge().

Changes:
- Updated 58 files to use sparse Document objects
- Added Performance Patterns section to AGENTS.md with optimization guidelines
- Applied pattern to Workers, Functions, Sites, Teams, VCS modules
- Updated app/controllers/api files (account, users, messaging)
- Updated app infrastructure files (realtime, general, init/resources, shared/api)

Exceptions maintained:
- Migration files (need full document updates by design)
- Cases with 6+ attributes (marginal benefit)
- Complex nested relationship logic
2026-03-06 17:05:19 +05:30
eldadfux
9d2036024a Refactor migration error handling to provide clearer connection error messages. Updated exception messages for migration sources to guide users on potential credential and network issues. 2026-03-05 08:24:32 +01:00
Hemachandar
598c71fb11
Move VCS events APIs to Modules (#11403)
* Move VCS events APIs to Modules

* trait

* lint

* fix external flow

* fix overriden vars

* feedback
2026-03-03 00:15:09 +05:30
eldadfux
ded05ebea2 Merge remote-tracking branch 'origin/1.8.x' into fix-users-optional-name-error 2026-02-26 12:09:12 +01:00
Eldad A. Fux
a71f3555ae
Merge pull request #11412 from appwrite/fix-better-error-for-functions
Fix better error for functions
2026-02-26 12:07:31 +01:00
eldadfux
47a81d165e Fix for user name to accept null and cast as string 2026-02-26 10:30:41 +01:00
Hemachandar
76965252d8
Move teams API to Modules (#11358)
* Move teams API to Modules

* lint

* Move team prefs & logs API to Modules (#11359)

* Move team prefs & logs API to Modules

* format

* missin desc

* Move team memberships API to Modules (#11362)

* Move team memberships API to Modules

* fix config dir

* Cloud parity

* params

* Cloud conflicts

* refactor

* prop

* refactor

* set teamId

* feedback

* feedback 2

* fix url-encoding
2026-02-26 11:18:29 +05:30
eldadfux
159da8ba31 Fix 500 errors where we don't report duplication properly 2026-02-25 23:58:22 +01:00
Damodar Lohani
244606ff1d
Revert "Fix: add missing sites bandwidth to project usage" 2026-02-25 12:56:05 +05:45
Eldad A. Fux
ac0aa81629
Merge pull request #11378 from appwrite/fix-missing-email-warning
OAuth provider handling fix
2026-02-24 14:36:09 +01:00
Jake Barnby
aa7dfd0bd1
Merge pull request #11312 from appwrite/feat-mongodb 2026-02-24 09:32:22 +00:00
Damodar Lohani
2898d57243 Fix: Add missing sites bandwidth in the project usage 2026-02-24 06:26:52 +00:00
Jake Barnby
1cb7c4b3f6 Merge remote-tracking branch 'origin/1.8.x' into feat-mongodb
# Conflicts:
#	.gitignore
#	composer.lock
#	tests/e2e/Services/Teams/TeamsCustomClientTest.php
2026-02-24 14:06:57 +13:00
Matej Bačo
f8783faf1e
Merge branch '1.8.x' into fix-email-url-params-encoding 2026-02-23 16:52:32 +01:00
Matej Bačo
2b6b66d8a4 Remove html encoding for urls 2026-02-23 12:45:18 +01:00
Jake Barnby
0019f01492
Merge branch '1.8.x' into feat-mongodb 2026-02-23 21:21:26 +13:00
eldadfux
addba2cdb7 Refactor OAuth provider checks in account controller
Updated the handling of OAuth provider configurations to ensure that defaults are set when parameters are missing. This change improves error handling by checking for null values and ensuring class existence before proceeding with OAuth operations.
2026-02-22 11:42:12 +01:00
Matej Bačo
e2bc3afce6 Fix url params in redirect URLs 2026-02-20 11:15:59 +01:00
eldadfux
f9ed35ed8a Enhance error handling for project database configuration
* Added checks to ensure project references a valid database and throws exceptions if not configured.
* Improved error messaging for non-existent projects in VCS controller.
2026-02-19 20:28:29 +01:00
Jake Barnby
b645721e14 fix: resolve CI failures from 1.8.x merge
- Remove unused WhiteList import in teams.php (linter fix)
- Add missing $teamId and $newTeam params to setupProject() in ProjectsBase.php (fixes 401 errors in all Projects tests)
- Filter execution logs by requestPath in testSSRLogs to avoid picking up screenshot worker executions

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-20 02:46:23 +13:00
Jake Barnby
8a6ddeef30
Merge branch '1.8.x' into feat-mongodb 2026-02-20 01:33:02 +13:00
Hemachandar
14e79f34db
Populate project-specific roles (#11209)
* Populate project-specific roles

* better comments

* simplify

* privileged user

* update permissions

* feedback

* lint

* only read + cleanup

* fix role length

* scopes

* not api-key

* cl-ignore group

* rename

* ciIgnore

* base scope

* change base scope

* fix projects

* copilot suggestion
2026-02-19 16:48:39 +05:30
Hemachandar
e902d3b6ad
fix: sanitize branch names for valid domain generation (#11245)
* fix: sanitize branch names for valid domain generation

Branch names containing invalid domain characters (like '/') were being
used directly when creating VCS preview domains, resulting in invalid
domains like 'branch-abc/test.appwrite.network'. This adds a Domain
helper class that sanitizes branch names by replacing invalid characters
with hyphens before generating domains.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* refactor: use Text constants for branch name sanitization

Replace regex with explicit character validation using Utopia Text
constants for better readability and maintainability.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Move to transformation adapter

* lint

* tiny

* fix test

* ut

* use Filter

* lint

* more lint

* simplify

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-19 14:37:01 +05:30
Jake Barnby
e26bac1e6e fix: resolve merge conflicts in projects.php template endpoints
Merge from 1.8.x left 6 unresolved conflicts in SMS/email template
endpoints. Resolved by keeping both the dynamic UID validator from
feat-mongodb and the strict WhiteList comparison from 1.8.x.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 03:41:36 +13:00
Jake Barnby
3bf594ecae
Merge branch '1.8.x' into feat-mongodb 2026-02-18 12:09:43 +00:00
Harsh Mahajan
f1f03fd35e fix: preserve template type casing in specs 2026-02-18 16:22:33 +05:30
Jake Barnby
51af714ea8
Merge branch '1.8.x' into feat-mongodb 2026-02-17 08:38:34 +00:00
Chirag Aggarwal
cc0d63bf03 chore: bump storage lib to remove deprecation warnings 2026-02-17 10:55:37 +05:30
Jake Barnby
c9aa80473d fix: Correct import ordering for WhiteList in teams controller
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-13 02:47:45 +13:00
Jake Barnby
0e6fa7f300 fix: Add missing WhiteList import in teams controller
The WhiteList validator was used at lines 486 and 1090 but never imported,
causing a "Class not found" error and 500 response instead of proper validation.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-13 02:36:29 +13:00
Jake Barnby
5590f0bcd0 Merge remote-tracking branch 'origin/1.8.x' into feat-mongodb
# Conflicts:
#	.env
#	.github/workflows/tests.yml
#	app/controllers/api/projects.php
#	app/controllers/api/teams.php
#	app/init/registers.php
#	app/views/install/compose.phtml
#	composer.json
#	composer.lock
#	docker-compose.yml
#	src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Create.php
#	src/Appwrite/Platform/Tasks/Install.php
#	src/Appwrite/Platform/Tasks/Upgrade.php
#	tests/e2e/Services/Databases/Legacy/DatabasesBase.php
#	tests/e2e/Services/Databases/TablesDB/DatabasesBase.php
2026-02-12 23:35:21 +13:00
Chirag Aggarwal
b2f4c4227e
Merge branch '1.8.x' into fix/cli-static-setresource 2026-02-11 12:10:35 +05:30
Chirag Aggarwal
161b971f53 Fix oauth redirect custom scheme state 2026-02-11 10:11:04 +05:30
Matej Bačo
e2071bd5dd add backwards compatibility 2026-02-10 11:48:29 +01:00
Matej Bačo
0621a32aa6 Fix tests; speed up tests; fix 5xx error 2026-02-10 11:43:22 +01:00
Matej Bačo
e1cbbe3943 Merge branch '1.8.x' into feat-list-api-keys-queries 2026-02-10 10:46:56 +01:00
Matej Bačo
226e36db95
Merge pull request #11277 from appwrite/feat-api-key-custom-id
Feat: custom ID for API keys
2026-02-10 10:46:00 +01:00
Chirag Aggarwal
2d05d608f4 Upgrade utopia-php dependencies and fix namespace changes
- Upgrade utopia-php/cli from 0.15 to 0.22
- Upgrade utopia-php/analytics from 0.10 to 0.15
- Upgrade utopia-php/orchestration from 0.9 to 0.19
- Use dev branches for utopia-php/framework and utopia-php/platform
- Remove utopia-php/swoole dependency (merged into framework)
- Migrate Utopia\CLI\Console to Utopia\Console across all files
- Migrate Utopia\Http to Utopia\Http\Http namespace
- Migrate Utopia\Swoole\Files to Utopia\Http\Files (now instance-based)
- Convert static CLI::setResource() calls to instance-based Dependency API
- Fix StatsResources task named parameter mismatch
2026-02-10 10:34:24 +05:30
Matej Bačo
a87263a571 Fix failing test 2026-02-09 20:07:33 +01:00
Matej Bačo
dafa97879c AI review fixes 2026-02-09 17:12:30 +01:00
Matej Bačo
a263afeff1 AI quality fixes 2026-02-09 17:10:00 +01:00
Matej Bačo
29915ddd3b Manual fixes of agent code 2026-02-09 16:58:44 +01:00
Matej Bačo
e666dc9504 AI review fixes 2026-02-09 16:42:14 +01:00
Matej Bačo
7bf5f2d360 Fix bug 5xx error 2026-02-09 15:55:35 +01:00
Matej Bačo
6df5556473 Implement queries param to list api keys 2026-02-09 14:58:36 +01:00
Matej Bačo
615aff0714 Allow custom ID for API keys 2026-02-09 14:34:05 +01:00
Matej Bačo
525b929e54 Fix implementation, add tests 2026-02-09 13:57:19 +01:00
Matej Bačo
36c87d109a Fix rule oauth flow 2026-02-09 13:45:18 +01:00