Commit graph

7060 commits

Author SHA1 Message Date
ArnabChatterjee20k
f6655343c7 pr comments addressed
* Added new exception `MIGRATION_DATABASE_TYPE_UNSUPPORTED` with proper error metadata and HTTP 400 response.
* Replaced generic CSV database type errors with the new migration-specific exception for clearer error handling.
* Added support for `DOCUMENTSDB` in migration transfer resource service mapping.
* Fixed Appwrite report initialization by correctly injecting `getDatabasesDB`.
* Updated database adapter initialization to conditionally disable attribute support for `DOCUMENTSDB`.
* Moved `setSupportForAttributes` logic from pool initialization to database resource creation.
* Removed duplicate `getDatabasesDB` resource definition and redundant database event listener setup.
* Cleaned up unused variables and minor code inconsistencies.
* Fixed docblock formatting in `TransactionState`.
* Adjusted metrics handling in VectorDB embeddings text creation (removed unnecessary trigger/reset flow).
2026-03-10 14:30:57 +05:30
ArnabChatterjee20k
d6bc9f120e Merge remote-tracking branch 'origin/1.8.x' into sync-mongodb 2026-03-09 15:50:48 +05:30
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
ArnabChatterjee20k
e84a26be76 Merge remote-tracking branch 'origin/1.8.x' into sync-mongodb 2026-03-05 12:11:44 +05:30
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
ArnabChatterjee20k
abf497d509 Merge remote-tracking branch 'origin/1.8.x' into sync-mongodb 2026-02-27 17:19:31 +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
ArnabChatterjee20k
3287ef6a57 Merge remote-tracking branch 'origin/1.8.x' into sync-mongodb 2026-02-26 16:33:56 +05:30
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
ArnabChatterjee20k
681c9743b1 added controllers 2026-02-25 16:09:28 +05:30
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
ArnabChatterjee20k
cc9df4f5c5 Merge remote-tracking branch 'origin/1.8.x' into documents-db-api 2026-02-23 13:09:49 +05:30
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
ArnabChatterjee20k
51d769b0a1 Merge remote-tracking branch 'origin/1.8.x' into documents-db-api 2026-02-20 13:58:56 +05:30
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
ArnabChatterjee20k
2d0140f705 Merge remote-tracking branch 'origin/1.8.x' into documents-db-api 2026-02-18 16:01:55 +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
ArnabChatterjee20k
ae33104ecf added admin auth to the index creation 2026-02-11 18:19:46 +05:30
ArnabChatterjee20k
61f778196b Merge remote-tracking branch 'origin/1.8.x' into documents-db-api 2026-02-11 13:58:43 +05:30
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
ArnabChatterjee20k
93897f86d0 Merge remote-tracking branch 'origin/1.8.x' into documents-db-api 2026-02-10 15:34:51 +05:30
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