Skip to content

fix(deps): migrate mock server for Console 0.3 - #1990

Merged
ChiragAgg5k merged 5 commits into
mainfrom
renovate/utopia-php-console-0.x
Oct 22, 2026
Merged

ChiragAgg5k merged 5 commits into
mainfrom
renovate/utopia-php-console-0.x

Conversation

@renovate-appwrite

@renovate-appwrite renovate-appwrite Bot commented Oct 9, 2026 •

Copy link
Copy Markdown
Contributor

Console 0.3 requires PHP 8.5 and validators 1.x. The old mock-server framework, Swoole adapter and database dependencies could not resolve that combination, leaving the Renovate version bump with a stale, incompatible lockfile.

This migrates the mock server to PHP 8.5 and the HTTP framework’s built-in Swoole adapter, regenerates the lockfile with Console 0.3.0, and adapts headers, request injection and model validation while preserving the SDK fixture responses. HTTP reuses the existing WebSocket listener with the framework’s per-request coroutine context. Unused database response helpers are removed; the upload fixture keeps its fixed file ID without the database package. MQTT retains its separate locked dependency set.

The framework is deliberately pinned to 2.0.0-rc33, which supports validators 1.x. rc34 requires validators 2.x and conflicts with Console 0.3. The router in rc33 drops literal 0 segments during registration, so the nullable-path fixture uses validated route parameters and retains its original concrete-path success markers.

Validation:

  • PHP 8.5, Node 26 and Chromium end-to-end suites: 3 tests, 744 assertions passed, including realtime and MQTT push.
  • Targeted PHPStan and PHPCS checks passed; repository lint and Rector checks passed.
  • Both Composer manifests validate, and the PHP 8.5 runtime passes Composer’s installed dependency platform checks.
  • Standards and behavior reviews found no blockers.
  • CLI Go 1.26 end-to-end suite: 1 test, 25 assertions passed, including Apple sign-in and APNs. The first attempt failed in the unchanged filesystem watcher’s timing-sensitive test; the complete suite passed on retry.
  • Flutter Stable end-to-end suite: 1 test, 283 assertions passed, including cookie persistence, realtime, MQTT and Android background delivery. The migration now uses the emitted lowercase cookie name for lookups, matching the old Swoole adapter’s behavior.
  • Local end-to-end total: 5 tests, 1,052 assertions passed.
  • Full GitHub CI is pending. The latest Node 26 job failed before testing because the Docker image pull returned HTTP 502; a targeted retry is queued after that workflow completes.

@renovate-appwrite renovate-appwrite Bot added the dependencies Pull requests that update a dependency file label Oct 9, 2026
@renovate-appwrite

Copy link
Copy Markdown
Contributor Author

⚠️ Artifact update problem

Renovate failed to update an artifact related to this branch. You probably do not want to merge this PR as-is.

♻ Renovate will retry this branch, including artifacts, only when one of the following happens:

  • any of the package files in this branch needs updating, or
  • the branch becomes conflicted, or
  • you click the rebase/retry checkbox if found above, or
  • you rename this PR's title to start with "rebase!" to trigger it manually

The artifact failure details are included below:

File name: mock-server/composer.lock
Command failed: composer update utopia-php/console:0.3.0 --with-all-dependencies --ignore-platform-req=ext-* --ignore-platform-req=lib-* --no-ansi --no-interaction --no-scripts --no-autoloader --no-plugins --minimal-changes
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - Root composer.json requires utopia-php/console ^0.3 -> satisfiable by utopia-php/console[0.3.0].
    - utopia-php/console 0.3.0 requires utopia-php/validators ^1.0 -> found utopia-php/validators[1.0.0, 1.0.1] but these were not loaded, likely because it conflicts with another require.


@hansi-codes

hansi-codes Bot commented Oct 9, 2026 •

Copy link
Copy Markdown

🟢 Tier S · Ready to merge

The incremental changes preserve the cookie round trip and only clarify the existing dependency separation; I found no new issue requiring a fix.

Migrates the HTTP mock server to PHP 8.5 and the framework’s built-in Swoole adapter, updating request handling and validation for Console 0.3 while preserving the SDK fixture responses. The HTTP dependency lock is regenerated with the compatible framework and validator versions; the MQTT broker continues to load its independently locked dependencies. The migration also removes unused database-backed helpers and retains the upload fixture’s fixed file ID.

Latest changes: The follow-up lowercases the cookie fixture name in both the response and request checks, and clarifies in the Compose comments that MQTT uses its own locked vendor dependencies.

Verdict New comments Fixed Still open
💬 Commented 0 0 0

Note

@renovate-appwrite[bot] does not have write access to this repository, so Hansi does not approve automatically. A maintainer can review and approve.

📂 Walkthrough · 13
File Change
mock-server/Dockerfile Uses PHP 8.5 for the mock server and builds the MQTT broker’s separately locked dependencies.
mock-server/app/http.php Migrates HTTP routing and request handling to the framework Swoole adapter, updates validation and fixtures, and uses a consistent lowercase cookie name for round trips.
mock-server/app/mqtt.php Loads the MQTT broker’s independently locked dependency set.
mock-server/composer.json Pins the compatible framework release and updates Console and PHP platform constraints.
mock-server/composer.lock Regenerates the HTTP mock server’s dependency lock for the new framework and validators.
mock-server/composer.mqtt.json Documents the MQTT broker’s separate dependency set.
mock-server/docker-compose.yml Clarifies that the MQTT service uses its own locked vendor dependencies.
mock-server/src/Utopia/Exception.php Updates nullable constructor parameter declarations and removes the unused Config import.
mock-server/src/Utopia/Filter.php, mock-server/src/Utopia/Model.php Removes unused database-dependent response helper files.
mock-server/src/Utopia/HttpAdapter.php Adds an HTTP Swoole adapter that reuses the WebSocket listener.
mock-server/src/Utopia/Model/Player.php Replaces the database model interface with a standalone immutable value model.
mock-server/src/Utopia/Response.php Retains response model constants on the framework HTTP response base and removes unused database response helpers.
mock-server/src/Utopia/Validator/Player.php Validates player request data as arrays and constructs the standalone model for type checks.

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

@hansi-codes hansi-codes Bot 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 · See the inline comments. Summary

Comment thread mock-server/composer.json
@ChiragAgg5k
ChiragAgg5k marked this pull request as draft October 22, 2026 16:27
@ChiragAgg5k ChiragAgg5k changed the title fix(deps): update dependency utopia-php/console to ^0.3 fix(deps): migrate mock server for Console 0.3 Oct 22, 2026
@ChiragAgg5k
ChiragAgg5k marked this pull request as ready for review October 22, 2026 20:55
@ChiragAgg5k
ChiragAgg5k merged commit ce0b484 into main Oct 22, 2026
100 of 101 checks passed
@renovate-appwrite
renovate-appwrite Bot deleted the renovate/utopia-php-console-0.x branch October 23, 2026 06:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant