Commit Graph

32166 Commits

Author SHA1 Message Date
Jake Barnby a952dad8d3 fix: add missing Role import and convert @group to PHP 8 attributes
- Add missing `use Utopia\Database\Helpers\Role` import in ProjectsBase.php
  (fixes "Class Role not found" fatal error)
- Convert @group ciIgnore docblock annotations to #[Group('ciIgnore')]
  PHP 8 attributes (PHPUnit 12 no longer supports docblock annotations)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-20 03:26:15 +13:00
Jake Barnby 2a535a2adc fix: exclude ciIgnore tests from CI and increase Realtime polling timeouts
- Add --exclude-group ciIgnore to paratest commands in tests.yml
  (the @group ciIgnore annotation was defined but never excluded)
- Increase attribute/index polling timeouts in RealtimeConsoleClientTest
  from 15s to 120s for Shared V2 stability

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-20 03:10:56 +13: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
Chirag Aggarwal 0af495f241 release some sdks 2026-02-19 18:15:05 +05:30
Jake Barnby 8a6ddeef30 Merge branch '1.8.x' into feat-mongodb 2026-02-20 01:33:02 +13:00
Jake Barnby 8a391e2e27 fix: mark transactionId as required param in transaction endpoints
Path parameters should not be optional. This caused SDK TypeScript
build failures where transactionId was typed as string | undefined.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-20 00:36:41 +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
Chirag Aggarwal 035227312f add back spacing 2026-02-19 15:53:00 +05:30
Chirag Aggarwal fe48882e6c feat(sdks): automate sdk version/changelog with assistant 2026-02-19 15:39:11 +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
Matej Bačo cdb6a2985f Merge pull request #11355 from appwrite/fix-rule-domains
Convert rule domains to lowercase
2026-02-19 09:42:34 +01:00
Jake Barnby c2e4ddc177 fix: bump utopia-php/database to 5.3.2
Includes fix for empty orderAsc() attribute mapping in MongoDB adapter
that caused subQueryVariables filter to hang and crash the service.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 16:05:47 +13:00
Jake Barnby ce0b7ab455 fix: increase function deployment build timeout to 4 minutes
FunctionsBase deployment polling was only 100 seconds, insufficient
under CI load when build workers are busy. Increased to 240 seconds
for both deployment readiness and activation checks.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 06:10:18 +13:00
Jake Barnby c1cb7bdc8e fix: increase schema polling timeouts to 15 minutes
Spatial attribute creation under parallel CI load consistently exceeds
10 minutes. Increased both waitForAllAttributes and waitForAllIndexes
from 10/8 minutes to 15 minutes to accommodate heavy parallel load.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 05:12:09 +13:00
Hemachandar 702484c27b lowercase only id 2026-02-18 21:12:56 +05:30
Jake Barnby 54505c0600 fix: increase polling timeouts for CI stability
Spatial attribute creation under parallel MariaDB load and function
deployment builds under MongoDB can exceed previous limits. Increased
SchemaPolling timeout from 8 to 10 minutes and GraphQL function build
timeout from 2 to 4 minutes.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 04:21:49 +13:00
Chirag Aggarwal f0574f5079 Merge pull request #11357 from appwrite/chore-gitignore-specs
chore: move specs to dedicated repo and remove from git tracking
2026-02-18 20:17:06 +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 f8e29c6b38 fix: prevent testTimeout from deleting shared database
testTimeout was using setupDatabase() to get the shared database, creating
a collection within it, then deleting the entire database at cleanup. This
destroyed the shared Movies/Actors/Books collections, causing testNotSearch
and other tests relying on the shared database to fail with 404.

Fix: only delete the test collection, not the shared database. Also add
waitForAttribute to prevent intermittent failures from attribute not being
available when inserting documents.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 02:37:06 +13:00
Matej Bačo 243b439186 Merge pull request #11354 from appwrite/fix-screenshot-target
Fix: Target rule for screenshot
2026-02-18 13:42:07 +01:00
Chirag Aggarwal baa44ce0bb remove testspecs 2026-02-18 17:39:56 +05:30
Jake Barnby 3bf594ecae Merge branch '1.8.x' into feat-mongodb 2026-02-18 12:09:43 +00:00
Chirag Aggarwal 74c8be3fad fix workflow 2026-02-18 17:30:17 +05:30
Matej Bačo 2f32e312c8 Fix tests 2026-02-18 12:56:42 +01:00
Chirag Aggarwal 9bb76f5510 chore: merge 1.8.x and resolve spec file conflicts
Resolved modify/delete conflicts by keeping deletions of spec files,
as they now live in the dedicated appwrite/specs repository.
2026-02-18 17:24:40 +05:30
Chirag Aggarwal 8d82bc89a1 chore: remove specs from git tracking and add to gitignore 2026-02-18 17:13:07 +05:30
Harsh Mahajan add50aa489 Merge pull request #11356 from appwrite/fix/specs-template-type-casing
Fix/specs template type casing
2026-02-18 17:12:39 +05:30
Harsh Mahajan aa52908d03 Merge branch '1.8.x' into fix/specs-template-type-casing 2026-02-18 16:24:22 +05:30
Harsh Mahajan f1f03fd35e fix: preserve template type casing in specs 2026-02-18 16:22:33 +05:30
Hemachandar 8f3472d55b Convert rule domains to lowercase 2026-02-18 15:58:24 +05:30
Jake Barnby fa972093f4 fix: front-load fulltext search infrastructure into cached setup chain
Move the Books collection, attributes, and fulltext index creation into
the shared setupCollection/setupAttributes/setupIndexes cache chain so
they are processed early when the worker queue is less loaded. This
eliminates testNotSearch creating redundant infrastructure from scratch
at test time when the queue is overwhelmed with 830+ parallel tests.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-18 23:26:03 +13:00
Jake Barnby ddb392caf7 fix: increase SchemaPolling default timeouts from 4min to 8min
MariaDB attribute/index processing consistently times out under parallel
test load in CI with different tests failing each run. Increase all default
polling timeouts from 240s to 480s to handle worst-case MariaDB load.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-18 23:18:56 +13:00
Matej Bačo 84eb065eb0 Screenshot after rule ready 2026-02-18 11:07:31 +01:00
Matej Bačo 7956b47aa8 Target rule for screenshot 2026-02-18 11:06:56 +01:00
Jake Barnby dca375624c fix: add missing 202 assertions before schema polling waits
- Fix testSpatialDistanceInMeter: move assertEquals(202) BEFORE waitForIndex
  (was after, causing misleading 4-minute timeout on creation failure)
- Add 202 assertions to testSpatialAttributesMixedCollection attribute creation
- Add 202 assertion to testConcurrentTransactionConflicts attribute creation
- Add 202 assertion to fulltext search index creation
- Add 202 assertion to shared collection attribute creation

These ensure tests fail fast with clear errors if schema creation returns
an error, instead of pointlessly polling for 4 minutes.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-18 22:58:05 +13:00
Jake Barnby 3e0febca92 Revert "fix: increase SchemaPolling default timeouts from 4min to 6min"
This reverts commit 2a4c33be11.
2026-02-18 22:49:31 +13:00
Jake Barnby 2a4c33be11 fix: increase SchemaPolling default timeouts from 4min to 6min
MariaDB attribute/index processing consistently times out under parallel
test load in CI. Increase all default polling timeouts from 240s to 360s.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-18 22:39:07 +13:00
Jake Barnby 6582ec8e67 fix: register TYPE_ID in GraphQL Mapper and fix Schedules tests for ParaTest
- Add 'id' => Type::string() to GraphQL Mapper Registry defaults to handle
  Model::TYPE_ID used by Document and Row models ($sequence field)
- Refactor SchedulesConsoleClientTest to use static-cached setup helpers
  instead of @depends annotations, which don't work in ParaTest --functional mode

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-18 21:59:33 +13:00
Jake Barnby 2c5806d1e7 Revert "fix: revert accidentally committed working tree changes"
This reverts commit a3503f4124.

# Conflicts:
#	composer.lock
2026-02-18 21:45:54 +13:00
Chirag Aggarwal 6728754d3f Merge pull request #11353 from appwrite/feat/specs-pr-platform-filter
feat: add getPlatformsForPR and getSdksCommand overridable methods
2026-02-18 14:15:02 +05:30
Jake Barnby 43f7c99039 Merge branch 'feat-mongodb' of github.com:appwrite/appwrite into feat-mongodb 2026-02-18 21:44:48 +13:00
Jake Barnby c584a72496 Update lock 2026-02-18 21:44:32 +13:00
Jake Barnby ce64011551 Merge branch '1.8.x' into feat-mongodb 2026-02-18 08:42:56 +00:00
Jake Barnby d118bb2c59 Merge pull request #11331 from appwrite/feat-schedules-endpoints
Add schedules API endpoints
2026-02-18 08:40:23 +00:00
Jake Barnby a3503f4124 fix: revert accidentally committed working tree changes
Reverts composer.lock (database 5.3.0→5.2.1), Model.php TYPE_ID,
Document.php/Row.php $sequence type changes, and OpenAPI/Swagger
id type additions that were unintentionally included in dd1a3d82.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-18 20:58:54 +13:00
Prem Palanisamy bd2e788c2a Update utopia-php/database to 5.3.1 2026-02-18 07:31:37 +00:00
Jake Barnby 0d1a6e07b4 fix: use relative path for --log-junit so retry action can find JUnit XML
The retry action couldn't extract the container name from docker compose
exec commands to copy the JUnit XML. Using a relative path works because
CWD inside the container is /usr/src/code and the volume mount
./tests:/usr/src/code/tests makes the file accessible at the same
relative path on both container and host.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-18 20:30:48 +13:00
Chirag Aggarwal b2742ab932 glob changes 2026-02-18 12:58:39 +05:30
Chirag Aggarwal fe86578d3c try filtering examples 2026-02-18 12:39:37 +05:30
Jake Barnby dd1a3d8222 fix: adjust testCreateIndexes index count for MongoDB maxIndexLength=1024
MongoDB's maxIndexLength (1024) allows the 512+512 index to succeed,
resulting in 5 indexes instead of 4. Use conditional count and
assertContains for position-independent key checks.

Verified: 830/830 Database tests pass locally on MongoDB with paratest.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-18 19:59:20 +13:00