From be33726e7608ca0d199bf29face76ad7b5bb39e0 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Tue, 27 Oct 2020 08:20:52 +0200 Subject: [PATCH 001/111] Upgraded to php8 --- Dockerfile | 70 ++++++++++++++++++++++++++++++++++++++---------------- 1 file changed, 49 insertions(+), 21 deletions(-) diff --git a/Dockerfile b/Dockerfile index 9b394d5b13..9015d2ae42 100755 --- a/Dockerfile +++ b/Dockerfile @@ -12,13 +12,15 @@ RUN composer update --ignore-platform-reqs --optimize-autoloader \ --no-plugins --no-scripts --prefer-dist \ `if [ "$TESTING" != "true" ]; then echo "--no-dev"; fi` -FROM php:7.4-cli-alpine as step1 +FROM php:8.0.0RC2-cli-alpine as step1 ENV TZ=Asia/Tel_Aviv \ - PHP_REDIS_VERSION=5.3.0 \ - PHP_SWOOLE_VERSION=4.5.6 \ - PHP_XDEBUG_VERSION=sdebug_2_9-beta - + PHP_REDIS_VERSION=5.3.2 \ + PHP_SWOOLE_VERSION=v4.5.6 \ + PHP_IMAGICK_VERSION=master \ + PHP_YAML_VERSION=2.2.0b2 \ + PHP_MAXMINDDB_VERSION=v1.8.0 + RUN \ apk add --no-cache --virtual .deps \ make \ @@ -26,20 +28,21 @@ RUN \ autoconf \ gcc \ g++ \ - tar \ - wget \ git \ zlib-dev \ brotli-dev \ + yaml-dev \ + imagemagick \ + imagemagick-dev \ libmaxminddb-dev RUN docker-php-ext-install sockets RUN \ # Redis Extension - wget -q https://github.com/phpredis/phpredis/archive/$PHP_REDIS_VERSION.tar.gz && \ - tar -xf $PHP_REDIS_VERSION.tar.gz && \ - cd phpredis-$PHP_REDIS_VERSION && \ + git clone https://github.com/phpredis/phpredis.git && \ + cd phpredis && \ + git checkout $PHP_REDIS_VERSION && \ phpize && \ ./configure && \ make && make install && \ @@ -47,20 +50,38 @@ RUN \ ## Swoole Extension git clone https://github.com/swoole/swoole-src.git && \ cd swoole-src && \ - git checkout v$PHP_SWOOLE_VERSION && \ + git checkout $PHP_SWOOLE_VERSION && \ phpize && \ - ./configure --enable-sockets --enable-http2 && \ + ./configure --enable-http2 && \ + make && make install && \ + cd .. && \ + ## Imagick Extension + git clone https://github.com/Imagick/imagick && \ + cd imagick && \ + git checkout $PHP_IMAGICK_VERSION && \ + phpize && \ + ./configure && \ + make && make install && \ + cd .. && \ + ## YAML Extension + git clone https://github.com/php/pecl-file_formats-yaml && \ + cd pecl-file_formats-yaml && \ + git checkout $PHP_YAML_VERSION && \ + phpize && \ + ./configure && \ make && make install && \ cd .. && \ ## Maxminddb extension git clone https://github.com/maxmind/MaxMind-DB-Reader-php.git && \ - cd MaxMind-DB-Reader-php/ext && \ + cd MaxMind-DB-Reader-php && \ + git checkout $PHP_MAXMINDDB_VERSION && \ + cd ext && \ phpize && \ ./configure && \ make && make install && \ cd ../.. -FROM php:7.4-cli-alpine as final +FROM php:8.0.0RC2-cli-alpine as final LABEL maintainer="team@appwrite.io" @@ -112,6 +133,9 @@ RUN \ curl-dev \ && apk add --no-cache \ libstdc++ \ + certbot \ + docker-cli \ + brotli-dev \ yaml-dev \ imagemagick \ imagemagick-dev \ @@ -120,8 +144,6 @@ RUN \ docker-compose \ libmaxminddb \ libmaxminddb-dev \ - && pecl install imagick yaml \ - && docker-php-ext-enable imagick yaml \ && docker-php-ext-install sockets opcache pdo_mysql \ && apk del .deps \ && rm -rf /var/cache/apk/* @@ -129,9 +151,11 @@ RUN \ WORKDIR /usr/src/code COPY --from=step0 /usr/local/src/vendor /usr/src/code/vendor -COPY --from=step1 /usr/local/lib/php/extensions/no-debug-non-zts-20190902/swoole.so /usr/local/lib/php/extensions/no-debug-non-zts-20190902/ -COPY --from=step1 /usr/local/lib/php/extensions/no-debug-non-zts-20190902/redis.so /usr/local/lib/php/extensions/no-debug-non-zts-20190902/ -COPY --from=step1 /usr/local/lib/php/extensions/no-debug-non-zts-20190902/maxminddb.so /usr/local/lib/php/extensions/no-debug-non-zts-20190902/ +COPY --from=step1 /usr/local/lib/php/extensions/no-debug-non-zts-20200930/swoole.so /usr/local/lib/php/extensions/no-debug-non-zts-20200930/ +COPY --from=step1 /usr/local/lib/php/extensions/no-debug-non-zts-20200930/redis.so /usr/local/lib/php/extensions/no-debug-non-zts-20200930/ +COPY --from=step1 /usr/local/lib/php/extensions/no-debug-non-zts-20200930/imagick.so /usr/local/lib/php/extensions/no-debug-non-zts-20200930/ +COPY --from=step1 /usr/local/lib/php/extensions/no-debug-non-zts-20200930/yaml.so /usr/local/lib/php/extensions/no-debug-non-zts-20200930/ +COPY --from=step1 /usr/local/lib/php/extensions/no-debug-non-zts-20200930/maxminddb.so /usr/local/lib/php/extensions/no-debug-non-zts-20200930/ # Add Source Code COPY ./app /usr/src/code/app @@ -177,12 +201,16 @@ RUN mkdir -p /etc/letsencrypt/live/ && chmod -Rf 755 /etc/letsencrypt/live/ # Enable Extensions RUN echo extension=swoole.so >> /usr/local/etc/php/conf.d/swoole.ini RUN echo extension=redis.so >> /usr/local/etc/php/conf.d/redis.ini +RUN echo extension=imagick.so >> /usr/local/etc/php/conf.d/imagick.ini +RUN echo extension=yaml.so >> /usr/local/etc/php/conf.d/yaml.ini RUN echo extension=maxminddb.so >> /usr/local/etc/php/conf.d/maxminddb.ini RUN echo "opcache.preload_user=www-data" >> /usr/local/etc/php/conf.d/appwrite.ini RUN echo "opcache.preload=/usr/src/code/app/preload.php" >> /usr/local/etc/php/conf.d/appwrite.ini -RUN echo "opcache.enable_cli = 1" >> /usr/local/etc/php/conf.d/appwrite.ini +RUN echo "opcache.enable_cli=1" >> /usr/local/etc/php/conf.d/appwrite.ini +RUN echo "opcache.jit_buffer_size=100M" >> /usr/local/etc/php/conf.d/appwrite.ini +RUN echo "opcache.jit=1235" >> /usr/local/etc/php/conf.d/appwrite.ini EXPOSE 80 -CMD [ "php", "app/http.php", "-dopcache.preload=opcache.preload=/usr/src/code/app/preload.php" ] +CMD [ "php", "app/http.php", "-dopcache.preload=opcache.preload=/usr/src/code/app/preload.php" ] \ No newline at end of file From e5c5cb0a25b50bfe8e87edb7bdc692f04b82ace1 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Tue, 27 Oct 2020 08:34:02 +0200 Subject: [PATCH 002/111] Updated PDO PHP8 signature --- src/Appwrite/Extend/PDOStatement.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Appwrite/Extend/PDOStatement.php b/src/Appwrite/Extend/PDOStatement.php index a752f9f27f..a000bdedca 100644 --- a/src/Appwrite/Extend/PDOStatement.php +++ b/src/Appwrite/Extend/PDOStatement.php @@ -98,7 +98,7 @@ class PDOStatement extends PDOStatementNative return $result; } - public function fetchAll($how = null, $class_name = null, $ctor_args = null) + public function fetchAll(int $fetch_style = PDO::FETCH_BOTH, mixed ...$fetch_args) { $result = $this->PDOStatement->fetchAll(); From cb82657a584f10140486d2fe4687760a75c697f4 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Tue, 27 Oct 2020 08:48:19 +0200 Subject: [PATCH 003/111] Fix for PHP8 array_push --- src/Appwrite/Database/Document.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Appwrite/Database/Document.php b/src/Appwrite/Database/Document.php index 2a472b839a..e70fce113f 100644 --- a/src/Appwrite/Database/Document.php +++ b/src/Appwrite/Database/Document.php @@ -110,7 +110,8 @@ class Document extends ArrayObject break; case self::SET_TYPE_APPEND: $this[$key] = (!isset($this[$key]) || !\is_array($this[$key])) ? [] : $this[$key]; - \array_push($this[$key], $value); + // \array_push($this[$key], $value); + $this[$key][count($this[$key])] = $value; break; case self::SET_TYPE_PREPEND: $this[$key] = (!isset($this[$key]) || !\is_array($this[$key])) ? [] : $this[$key]; From 745860a68dce2bff3d5a18c6a42be6ec35526294 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Tue, 27 Oct 2020 09:48:39 +0200 Subject: [PATCH 004/111] Fixed reference --- src/Appwrite/Docker/Compose/Service.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Appwrite/Docker/Compose/Service.php b/src/Appwrite/Docker/Compose/Service.php index 476e9a40eb..c3af364836 100644 --- a/src/Appwrite/Docker/Compose/Service.php +++ b/src/Appwrite/Docker/Compose/Service.php @@ -21,7 +21,7 @@ class Service $ports = (isset($this->service['ports']) && is_array($this->service['ports'])) ? $this->service['ports'] : []; $this->service['ports'] = []; - array_walk($ports, function(&$value, &$key) { + array_walk($ports, function(&$value, $key) { $split = explode(':', $value); $this->service['ports'][ (isset($split[0])) ? $split[0] : '' From 146046a119c81362819965b33af5c9dab14a76d6 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Tue, 27 Oct 2020 17:33:13 +0200 Subject: [PATCH 005/111] Fixed mock params --- app/controllers/mock.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app/controllers/mock.php b/app/controllers/mock.php index 3f36a2238f..d5f284b900 100644 --- a/app/controllers/mock.php +++ b/app/controllers/mock.php @@ -270,10 +270,10 @@ App::get('/v1/mock/tests/general/oauth2') ->param('redirect_uri', '', new Host(['localhost']), 'OAuth2 Redirect URI.') // Important to deny an open redirect attack ->param('scope', '', new Text(100), 'OAuth2 scope list.') ->param('state', '', new Text(1024), 'OAuth2 state.') - ->action(function ($clientId, $redirectURI, $scope, $state, $response) { + ->action(function ($client_id, $redirect_uri, $scope, $state, $response) { /** @var Appwrite\Utopia\Response $response */ - $response->redirect($redirectURI.'?'.\http_build_query(['code' => 'abcdef', 'state' => $state])); + $response->redirect($redirect_uri.'?'.\http_build_query(['code' => 'abcdef', 'state' => $state])); }, ['response']); App::get('/v1/mock/tests/general/oauth2/token') @@ -286,14 +286,14 @@ App::get('/v1/mock/tests/general/oauth2/token') ->param('redirect_uri', '', new Host(['localhost']), 'OAuth2 Redirect URI.') ->param('client_secret', '', new Text(100), 'OAuth2 scope list.') ->param('code', '', new Text(100), 'OAuth2 state.') - ->action(function ($clientId, $redirectURI, $clientSecret, $code, $response) { + ->action(function ($client_id, $redirect_uri, $client_secret, $code, $response) { /** @var Appwrite\Utopia\Response $response */ - if ($clientId != '1') { + if ($client_id != '1') { throw new Exception('Invalid client ID'); } - if ($clientSecret != '123456') { + if ($client_secret != '123456') { throw new Exception('Invalid client secret'); } From 8bbdac232da59710c59ff67e7c9cf8ae07b53837 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Tue, 27 Oct 2020 20:42:42 +0200 Subject: [PATCH 006/111] Removed multiple docker-cli setups --- Dockerfile | 1 - 1 file changed, 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 75fc4b6faf..85d2b25cac 100755 --- a/Dockerfile +++ b/Dockerfile @@ -132,7 +132,6 @@ RUN \ && apk add --no-cache \ libstdc++ \ certbot \ - docker-cli \ brotli-dev \ yaml-dev \ imagemagick \ From 2996260e41e8ca019dec68077263437c60ed3cb1 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Tue, 27 Oct 2020 21:34:27 +0200 Subject: [PATCH 007/111] Added missing docs --- src/Appwrite/Extend/PDOStatement.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/Appwrite/Extend/PDOStatement.php b/src/Appwrite/Extend/PDOStatement.php index a000bdedca..46c33f6545 100644 --- a/src/Appwrite/Extend/PDOStatement.php +++ b/src/Appwrite/Extend/PDOStatement.php @@ -98,6 +98,14 @@ class PDOStatement extends PDOStatementNative return $result; } + /** + * Fetch All + * + * @param int $fetch_style + * @param mixed $fetch_args + * + * @return array|false + */ public function fetchAll(int $fetch_style = PDO::FETCH_BOTH, mixed ...$fetch_args) { $result = $this->PDOStatement->fetchAll(); From 42d9a64473cc63ac352effd2d11893d481ebd209 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Tue, 27 Oct 2020 23:56:47 +0200 Subject: [PATCH 008/111] New line :) --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 85d2b25cac..214c4a27fd 100755 --- a/Dockerfile +++ b/Dockerfile @@ -210,4 +210,4 @@ RUN echo "opcache.jit=1235" >> /usr/local/etc/php/conf.d/appwrite.ini EXPOSE 80 -CMD [ "php", "app/http.php", "-dopcache.preload=opcache.preload=/usr/src/code/app/preload.php" ] \ No newline at end of file +CMD [ "php", "app/http.php", "-dopcache.preload=opcache.preload=/usr/src/code/app/preload.php" ] From eb9730b606f61b88fc7df5c9f0c37b3d52508d5d Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Thu, 29 Oct 2020 00:34:21 +0200 Subject: [PATCH 009/111] Removed imagemagick dev --- Dockerfile | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 214c4a27fd..fa15430bc4 100755 --- a/Dockerfile +++ b/Dockerfile @@ -135,12 +135,10 @@ RUN \ brotli-dev \ yaml-dev \ imagemagick \ - imagemagick-dev \ + libmaxminddb-dev \ certbot \ docker-cli \ docker-compose \ - libmaxminddb \ - libmaxminddb-dev \ && docker-php-ext-install sockets opcache pdo_mysql \ && apk del .deps \ && rm -rf /var/cache/apk/* From b4037b9da3c3ada7e28646f2373173d73b1c8bdb Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Sat, 7 Nov 2020 20:10:28 +0200 Subject: [PATCH 010/111] Upgraded to RC3 --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 3cbf268f33..fef1d9046c 100755 --- a/Dockerfile +++ b/Dockerfile @@ -12,7 +12,7 @@ RUN composer update --ignore-platform-reqs --optimize-autoloader \ --no-plugins --no-scripts --prefer-dist \ `if [ "$TESTING" != "true" ]; then echo "--no-dev"; fi` -FROM php:8.0.0RC2-cli-alpine as step1 +FROM php:8.0.0RC3-cli-alpine as step1 ENV PHP_REDIS_VERSION=5.3.2 \ PHP_SWOOLE_VERSION=v4.5.6 \ @@ -80,7 +80,7 @@ RUN \ make && make install && \ cd ../.. -FROM php:8.0.0RC2-cli-alpine as final +FROM php:8.0.0RC3-cli-alpine as final LABEL maintainer="team@appwrite.io" From dda4f2935ae483198fe942726190145f6d7e97a9 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Sat, 21 Nov 2020 08:18:39 +0200 Subject: [PATCH 011/111] Updated RC version --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index fef1d9046c..ad3ea0e942 100755 --- a/Dockerfile +++ b/Dockerfile @@ -12,7 +12,7 @@ RUN composer update --ignore-platform-reqs --optimize-autoloader \ --no-plugins --no-scripts --prefer-dist \ `if [ "$TESTING" != "true" ]; then echo "--no-dev"; fi` -FROM php:8.0.0RC3-cli-alpine as step1 +FROM php:8.0.0RC5-cli-alpine as step1 ENV PHP_REDIS_VERSION=5.3.2 \ PHP_SWOOLE_VERSION=v4.5.6 \ @@ -80,7 +80,7 @@ RUN \ make && make install && \ cd ../.. -FROM php:8.0.0RC3-cli-alpine as final +FROM php:8.0.0RC5-cli-alpine as final LABEL maintainer="team@appwrite.io" From 4e83a988fc9c35ed35b9242680d931cf391de5ba Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Sat, 21 Nov 2020 10:02:25 +0200 Subject: [PATCH 012/111] Fixed tests --- src/Appwrite/Database/Document.php | 3 +-- src/Appwrite/Utopia/Response/Model/Platform.php | 10 +++++----- tests/e2e/Services/Database/DatabaseBase.php | 2 -- tests/e2e/Services/Locale/LocaleBase.php | 4 ++-- 4 files changed, 8 insertions(+), 11 deletions(-) diff --git a/src/Appwrite/Database/Document.php b/src/Appwrite/Database/Document.php index fe5c9f1d12..aa90fba106 100644 --- a/src/Appwrite/Database/Document.php +++ b/src/Appwrite/Database/Document.php @@ -110,8 +110,7 @@ class Document extends ArrayObject break; case self::SET_TYPE_APPEND: $this[$key] = (!isset($this[$key]) || !\is_array($this[$key])) ? [] : $this[$key]; - // \array_push($this[$key], $value); - $this[$key][count($this[$key])] = $value; + \array_push($this[$key], $value); break; case self::SET_TYPE_PREPEND: $this[$key] = (!isset($this[$key]) || !\is_array($this[$key])) ? [] : $this[$key]; diff --git a/src/Appwrite/Utopia/Response/Model/Platform.php b/src/Appwrite/Utopia/Response/Model/Platform.php index 06c61d3e1b..0791d5ecc4 100644 --- a/src/Appwrite/Utopia/Response/Model/Platform.php +++ b/src/Appwrite/Utopia/Response/Model/Platform.php @@ -35,11 +35,11 @@ class Platform extends Model 'description' => 'Platform Key. iOS bundle ID or Android package name. Empty string for other platforms.', 'example' => 'com.company.appname', ]) - // ->addRule('store', [ - // 'type' => self::TYPE_STRING, - // 'description' => 'Link to platform store.', - // 'example' => '', - // ]) + ->addRule('store', [ + 'type' => self::TYPE_STRING, + 'description' => 'App store or Google Play store ID.', + 'example' => '', + ]) ->addRule('hostname', [ 'type' => self::TYPE_STRING, 'description' => 'Web app hostname. Empty string for other platforms.', diff --git a/tests/e2e/Services/Database/DatabaseBase.php b/tests/e2e/Services/Database/DatabaseBase.php index f769184827..79d777f9ab 100644 --- a/tests/e2e/Services/Database/DatabaseBase.php +++ b/tests/e2e/Services/Database/DatabaseBase.php @@ -40,7 +40,6 @@ trait DatabaseBase ]); $this->assertEquals($actors['headers']['status-code'], 201); - $this->assertEquals($actors['body']['$collection'], 0); $this->assertEquals($actors['body']['name'], 'Actors'); $this->assertIsArray($actors['body']['$permissions']); $this->assertIsArray($actors['body']['$permissions']['read']); @@ -86,7 +85,6 @@ trait DatabaseBase ]); $this->assertEquals($movies['headers']['status-code'], 201); - $this->assertEquals($movies['body']['$collection'], 0); $this->assertEquals($movies['body']['name'], 'Movies'); $this->assertIsArray($movies['body']['$permissions']); $this->assertIsArray($movies['body']['$permissions']['read']); diff --git a/tests/e2e/Services/Locale/LocaleBase.php b/tests/e2e/Services/Locale/LocaleBase.php index cdfb0c726a..0ad3ed076b 100644 --- a/tests/e2e/Services/Locale/LocaleBase.php +++ b/tests/e2e/Services/Locale/LocaleBase.php @@ -123,8 +123,8 @@ trait LocaleBase $this->assertEquals(194, $response['body']['sum']); $this->assertIsArray($response['body']['phones']); $this->assertEquals($response['body']['phones'][0]['code'], '+1'); - $this->assertEquals($response['body']['phones'][0]['countryName'], 'United States'); - $this->assertEquals($response['body']['phones'][0]['countryCode'], 'US'); + $this->assertEquals($response['body']['phones'][0]['countryName'], 'Canada'); + $this->assertEquals($response['body']['phones'][0]['countryCode'], 'CA'); /** * Test for FAILURE From 02ef52c13dc782f934dc3ac38d01af53c63f87d8 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Tue, 1 Dec 2020 08:08:01 +0200 Subject: [PATCH 013/111] Official release tag! --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index ad3ea0e942..173b468401 100755 --- a/Dockerfile +++ b/Dockerfile @@ -12,7 +12,7 @@ RUN composer update --ignore-platform-reqs --optimize-autoloader \ --no-plugins --no-scripts --prefer-dist \ `if [ "$TESTING" != "true" ]; then echo "--no-dev"; fi` -FROM php:8.0.0RC5-cli-alpine as step1 +FROM php:8.0.0-cli-alpine as step1 ENV PHP_REDIS_VERSION=5.3.2 \ PHP_SWOOLE_VERSION=v4.5.6 \ @@ -80,7 +80,7 @@ RUN \ make && make install && \ cd ../.. -FROM php:8.0.0RC5-cli-alpine as final +FROM php:8.0.0-cli-alpine as final LABEL maintainer="team@appwrite.io" From 3190b05ec7c9159dd2d2a3c1e0fd1ce3da458900 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Sun, 13 Dec 2020 09:27:08 +0200 Subject: [PATCH 014/111] Upgraded Swoole version --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index d81161925b..ad0b778e55 100755 --- a/Dockerfile +++ b/Dockerfile @@ -15,7 +15,7 @@ RUN composer update --ignore-platform-reqs --optimize-autoloader \ FROM php:8.0.0-cli-alpine as step1 ENV PHP_REDIS_VERSION=5.3.2 \ - PHP_SWOOLE_VERSION=v4.5.8 \ + PHP_SWOOLE_VERSION=v4.5.9 \ PHP_IMAGICK_VERSION=master \ PHP_YAML_VERSION=2.2.0b2 \ PHP_MAXMINDDB_VERSION=v1.8.0 From 29311cb2be135c0d2ebf2fea1c392a06eb30913b Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Mon, 21 Dec 2020 09:23:43 +0200 Subject: [PATCH 015/111] Remove $collection tests, attribute has been removed --- tests/e2e/Services/Database/DatabaseCustomServerTest.php | 1 - 1 file changed, 1 deletion(-) diff --git a/tests/e2e/Services/Database/DatabaseCustomServerTest.php b/tests/e2e/Services/Database/DatabaseCustomServerTest.php index 2f0bdfc766..cb4d23c100 100644 --- a/tests/e2e/Services/Database/DatabaseCustomServerTest.php +++ b/tests/e2e/Services/Database/DatabaseCustomServerTest.php @@ -49,7 +49,6 @@ class DatabaseCustomServerTest extends Scope ]); $this->assertEquals($actors['headers']['status-code'], 201); - $this->assertEquals($actors['body']['$collection'], 0); $this->assertEquals($actors['body']['name'], 'Actors'); $this->assertIsArray($actors['body']['$permissions']); $this->assertIsArray($actors['body']['$permissions']['read']); From cbb058400666a15e67155f57d361dbd2533b673c Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Mon, 4 Jan 2021 01:29:04 +0200 Subject: [PATCH 016/111] Synced with 0.7 --- app/controllers/mock.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/mock.php b/app/controllers/mock.php index 8ee33e621a..7f88376b1d 100644 --- a/app/controllers/mock.php +++ b/app/controllers/mock.php @@ -308,7 +308,7 @@ App::get('/v1/mock/tests/general/oauth2/token') ->param('client_secret', '', new Text(100), 'OAuth2 scope list.') ->param('code', '', new Text(100), 'OAuth2 state.') ->inject('response') - ->action(function ($client_id, $redirectURI, $clientSecret, $code, $response) { + ->action(function ($client_id, $redirectURI, $client_secret, $code, $response) { /** @var Appwrite\Utopia\Response $response */ if ($client_id != '1') { From e8c1d3ae9d9a71f467c4af8eb9c806306c6eb2d0 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Fri, 15 Jan 2021 08:08:02 +0200 Subject: [PATCH 017/111] Updated dependencies --- Dockerfile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index ddaf2727b4..1b79798388 100755 --- a/Dockerfile +++ b/Dockerfile @@ -15,10 +15,10 @@ RUN composer update --ignore-platform-reqs --optimize-autoloader \ FROM php:8.0.0-cli-alpine as step1 ENV PHP_REDIS_VERSION=5.3.2 \ - PHP_SWOOLE_VERSION=v4.5.9 \ + PHP_SWOOLE_VERSION=v4.6.1 \ PHP_IMAGICK_VERSION=master \ - PHP_YAML_VERSION=2.2.0b2 \ - PHP_MAXMINDDB_VERSION=v1.8.0 + PHP_YAML_VERSION=2.2.1 \ + PHP_MAXMINDDB_VERSION=v1.9.0 RUN \ apk add --no-cache --virtual .deps \ From 4c1d5419f49284e9270b1836d2d4f8271bffd965 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Fri, 15 Jan 2021 11:25:04 +0200 Subject: [PATCH 018/111] Updated Influx SDK --- composer.json | 4 ++-- composer.lock | 31 ++++++++++++++++--------------- 2 files changed, 18 insertions(+), 17 deletions(-) diff --git a/composer.json b/composer.json index c393e67ae6..89e3995c91 100644 --- a/composer.json +++ b/composer.json @@ -50,13 +50,13 @@ "matomo/device-detector": "3.13.0", "dragonmantank/cron-expression": "3.0.1", "domnikl/statsd": "3.0.2", - "influxdb/influxdb-php": "1.15.1", + "influxdb/influxdb-php": "1.15.2", "phpmailer/phpmailer": "6.1.7", "chillerlan/php-qrcode": "4.3.0", "adhocore/jwt": "1.1.0" }, "require-dev": { - "swoole/ide-helper": "4.5.5", + "swoole/ide-helper": "4.6.1", "appwrite/sdk-generator": "0.4.4", "phpunit/phpunit": "9.4.2", "vimeo/psalm": "4.1.1" diff --git a/composer.lock b/composer.lock index 3fcb20b73d..6e0661b7b2 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "2a235acbc30e22872101713bf3602351", + "content-hash": "0cc375bf8138012dbf1561c031556fe1", "packages": [ { "name": "adhocore/jwt", @@ -644,24 +644,25 @@ }, { "name": "influxdb/influxdb-php", - "version": "1.15.1", + "version": "1.15.2", "source": { "type": "git", "url": "https://github.com/influxdata/influxdb-php.git", - "reference": "447acb600969f9510c9f1900a76d442fc3537b0e" + "reference": "d6e59f4f04ab9107574fda69c2cbe36671253d03" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/influxdata/influxdb-php/zipball/447acb600969f9510c9f1900a76d442fc3537b0e", - "reference": "447acb600969f9510c9f1900a76d442fc3537b0e", + "url": "https://api.github.com/repos/influxdata/influxdb-php/zipball/d6e59f4f04ab9107574fda69c2cbe36671253d03", + "reference": "d6e59f4f04ab9107574fda69c2cbe36671253d03", "shasum": "" }, "require": { "guzzlehttp/guzzle": "^6.0|^7.0", - "php": "^5.5 || ^7.0" + "php": "^5.5 || ^7.0 || ^8.0" }, "require-dev": { - "phpunit/phpunit": "^5.7" + "dms/phpunit-arraysubset-asserts": "^0.2.1", + "phpunit/phpunit": "^9.5" }, "suggest": { "ext-curl": "Curl extension, needed for Curl driver", @@ -703,9 +704,9 @@ ], "support": { "issues": "https://github.com/influxdata/influxdb-php/issues", - "source": "https://github.com/influxdata/influxdb-php/tree/1.15.1" + "source": "https://github.com/influxdata/influxdb-php/tree/1.15.2" }, - "time": "2020-09-18T13:24:03+00:00" + "time": "2020-12-26T17:45:17+00:00" }, { "name": "matomo/device-detector", @@ -4536,16 +4537,16 @@ }, { "name": "swoole/ide-helper", - "version": "4.5.5", + "version": "4.6.1", "source": { "type": "git", "url": "https://github.com/swoole/ide-helper.git", - "reference": "aefd9d15e00cf14b89a5ed87cfa3bd79c9889028" + "reference": "5b36a9722eb8c693ff9831023cfb807474eab07c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/swoole/ide-helper/zipball/aefd9d15e00cf14b89a5ed87cfa3bd79c9889028", - "reference": "aefd9d15e00cf14b89a5ed87cfa3bd79c9889028", + "url": "https://api.github.com/repos/swoole/ide-helper/zipball/5b36a9722eb8c693ff9831023cfb807474eab07c", + "reference": "5b36a9722eb8c693ff9831023cfb807474eab07c", "shasum": "" }, "require-dev": { @@ -4568,9 +4569,9 @@ "description": "IDE help files for Swoole.", "support": { "issues": "https://github.com/swoole/ide-helper/issues", - "source": "https://github.com/swoole/ide-helper/tree/4.5.5" + "source": "https://github.com/swoole/ide-helper/tree/4.6.1" }, - "time": "2020-10-14T18:05:12+00:00" + "time": "2021-01-11T19:15:13+00:00" }, { "name": "symfony/console", From 8373be65d08fa4db0e3ff24019ba53213812e773 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Fri, 15 Jan 2021 19:19:48 +0200 Subject: [PATCH 019/111] Fix for swoole error --- app/workers/functions.php | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/app/workers/functions.php b/app/workers/functions.php index 577e847337..f3d83e19a0 100644 --- a/app/workers/functions.php +++ b/app/workers/functions.php @@ -18,8 +18,6 @@ require_once __DIR__.'/../init.php'; \cli_set_process_title('Functions V1 Worker'); -Runtime::setHookFlags(SWOOLE_HOOK_ALL); - Console::success(APP_NAME.' functions worker v1 has started'); $environments = Config::getParam('environments'); @@ -29,11 +27,11 @@ $environments = Config::getParam('environments'); */ $warmupStart = \microtime(true); -Co\run(function() use ($environments) { // Warmup: make sure images are ready to run fast 🚀 - Swoole\Runtime::enableCoroutine(SWOOLE_HOOK_ALL); +// Co\run(function() use ($environments) { // Warmup: make sure images are ready to run fast 🚀 + // Swoole\Runtime::enableCoroutine(SWOOLE_HOOK_ALL); foreach($environments as $environment) { - go(function() use ($environment) { + // go(function() use ($environment) { $stdout = ''; $stderr = ''; @@ -53,9 +51,9 @@ Co\run(function() use ($environments) { // Warmup: make sure images are ready t if(!empty($stderr)) { Console::error($stderr); } - }); + // }); } -}); +// }); $warmupEnd = \microtime(true); $warmupTime = $warmupEnd - $warmupStart; From 70e0e5b1a32068cc67cd8f2358d86d8dd9dc7471 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Sat, 30 Jan 2021 12:00:08 +0200 Subject: [PATCH 020/111] Upgraded Swoole --- Dockerfile | 2 +- composer.json | 2 +- composer.lock | 14 +++++++------- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/Dockerfile b/Dockerfile index 77fd8184a1..ad1ca04ceb 100755 --- a/Dockerfile +++ b/Dockerfile @@ -15,7 +15,7 @@ RUN composer update --ignore-platform-reqs --optimize-autoloader \ FROM php:8.0.0-cli-alpine as step1 ENV PHP_REDIS_VERSION=5.3.2 \ - PHP_SWOOLE_VERSION=v4.6.1 \ + PHP_SWOOLE_VERSION=v4.6.2 \ PHP_IMAGICK_VERSION=master \ PHP_YAML_VERSION=2.2.1 \ PHP_MAXMINDDB_VERSION=v1.9.0 diff --git a/composer.json b/composer.json index 72581325f2..2cc7b4c125 100644 --- a/composer.json +++ b/composer.json @@ -58,7 +58,7 @@ "adhocore/jwt": "1.1.0" }, "require-dev": { - "swoole/ide-helper": "4.6.1", + "swoole/ide-helper": "4.6.2", "appwrite/sdk-generator": "0.4.5", "phpunit/phpunit": "9.4.2", "vimeo/psalm": "4.1.1" diff --git a/composer.lock b/composer.lock index 125c36208f..acb00eae38 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "5ededf479d2aef4e9df315fcd7ea2970", + "content-hash": "736c1aaf5e95e1bd4d5b2ce67bb7cbd5", "packages": [ { "name": "adhocore/jwt", @@ -4644,16 +4644,16 @@ }, { "name": "swoole/ide-helper", - "version": "4.6.1", + "version": "4.6.2", "source": { "type": "git", "url": "https://github.com/swoole/ide-helper.git", - "reference": "5b36a9722eb8c693ff9831023cfb807474eab07c" + "reference": "62d923e3406d4d9c5a4749d810d11e2beb201abe" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/swoole/ide-helper/zipball/5b36a9722eb8c693ff9831023cfb807474eab07c", - "reference": "5b36a9722eb8c693ff9831023cfb807474eab07c", + "url": "https://api.github.com/repos/swoole/ide-helper/zipball/62d923e3406d4d9c5a4749d810d11e2beb201abe", + "reference": "62d923e3406d4d9c5a4749d810d11e2beb201abe", "shasum": "" }, "require-dev": { @@ -4676,9 +4676,9 @@ "description": "IDE help files for Swoole.", "support": { "issues": "https://github.com/swoole/ide-helper/issues", - "source": "https://github.com/swoole/ide-helper/tree/4.6.1" + "source": "https://github.com/swoole/ide-helper/tree/4.6.2" }, - "time": "2021-01-11T19:15:13+00:00" + "time": "2021-01-26T00:17:29+00:00" }, { "name": "symfony/console", From a856d618deaf7d1a92c1176eb922186a85556e6c Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Sat, 6 Feb 2021 00:17:06 +0200 Subject: [PATCH 021/111] Updated PHP version --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index ad1ca04ceb..20a2a80177 100755 --- a/Dockerfile +++ b/Dockerfile @@ -12,7 +12,7 @@ RUN composer update --ignore-platform-reqs --optimize-autoloader \ --no-plugins --no-scripts --prefer-dist \ `if [ "$TESTING" != "true" ]; then echo "--no-dev"; fi` -FROM php:8.0.0-cli-alpine as step1 +FROM php:8.0-cli-alpine as step1 ENV PHP_REDIS_VERSION=5.3.2 \ PHP_SWOOLE_VERSION=v4.6.2 \ @@ -80,7 +80,7 @@ RUN \ make && make install && \ cd ../.. -FROM php:8.0.0-cli-alpine as final +FROM php:8.0-cli-alpine as final LABEL maintainer="team@appwrite.io" From 429ac1098c098626125ad1dbddbdb59b4fc108a3 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Sat, 6 Feb 2021 07:35:42 +0200 Subject: [PATCH 022/111] Fixed JSON syntax --- src/Appwrite/Migration/Version/V06.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Appwrite/Migration/Version/V06.php b/src/Appwrite/Migration/Version/V06.php index 90cdb3e2a9..60bb8d3471 100644 --- a/src/Appwrite/Migration/Version/V06.php +++ b/src/Appwrite/Migration/Version/V06.php @@ -34,8 +34,8 @@ class V06 extends Migration break; case Database::SYSTEM_COLLECTION_KEYS: if ($document->getAttribute('secret', null)) { - $json = \json_decode($document->getAttribute('secret')); - if ($json->{'data'} || $json->{'method'} || $json->{'iv'} || $json->{'tag'} || $json->{'version'}) + $json = \json_decode($document->getAttribute('secret'), true); + if ($json['data'] || $json['method'] || $json['iv'] || $json['tag'] || $json['version']) { Console::log('Secret already encrypted. Skipped: ' . $document->getId()); break; From 45fff3e51fc9b3ee587cbc85b24e0604c08d3e2c Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Sat, 6 Feb 2021 10:27:07 +0200 Subject: [PATCH 023/111] Fixed test for php8 --- src/Appwrite/Migration/Version/V06.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Appwrite/Migration/Version/V06.php b/src/Appwrite/Migration/Version/V06.php index 60bb8d3471..e4fbc77718 100644 --- a/src/Appwrite/Migration/Version/V06.php +++ b/src/Appwrite/Migration/Version/V06.php @@ -35,7 +35,7 @@ class V06 extends Migration case Database::SYSTEM_COLLECTION_KEYS: if ($document->getAttribute('secret', null)) { $json = \json_decode($document->getAttribute('secret'), true); - if ($json['data'] || $json['method'] || $json['iv'] || $json['tag'] || $json['version']) + if (is_array($json)) { Console::log('Secret already encrypted. Skipped: ' . $document->getId()); break; From a99133d5d8d3ddba27708d91b873ab0a6b90b9ea Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Tue, 9 Feb 2021 12:37:34 +0200 Subject: [PATCH 024/111] Updated Swoole version --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 20a2a80177..f6de55199f 100755 --- a/Dockerfile +++ b/Dockerfile @@ -15,7 +15,7 @@ RUN composer update --ignore-platform-reqs --optimize-autoloader \ FROM php:8.0-cli-alpine as step1 ENV PHP_REDIS_VERSION=5.3.2 \ - PHP_SWOOLE_VERSION=v4.6.2 \ + PHP_SWOOLE_VERSION=v4.6.3 \ PHP_IMAGICK_VERSION=master \ PHP_YAML_VERSION=2.2.1 \ PHP_MAXMINDDB_VERSION=v1.9.0 From 8a93f404e985b6d3ecb689a2e889fe8f2c323f9c Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Fri, 9 Apr 2021 12:35:44 +0200 Subject: [PATCH 025/111] deps: update dependencies --- composer.json | 25 +- composer.lock | 830 ++++++++++++++++++++------------------------------ 2 files changed, 344 insertions(+), 511 deletions(-) diff --git a/composer.json b/composer.json index e729855978..d5a161c356 100644 --- a/composer.json +++ b/composer.json @@ -35,7 +35,7 @@ "ext-zlib": "*", "ext-sockets": "*", - "appwrite/php-clamav": "1.0.*", + "appwrite/php-clamav": "1.1.*", "utopia-php/framework": "0.12.*", "utopia-php/abuse": "0.4.*", @@ -45,28 +45,28 @@ "utopia-php/cli": "0.10.0", "utopia-php/config": "0.2.*", "utopia-php/locale": "0.3.*", - "utopia-php/registry": "0.2.*", + "utopia-php/registry": "0.4.*", "utopia-php/preloader": "0.2.*", - "utopia-php/domains": "0.2.*", + "utopia-php/domains": "1.1.*", "utopia-php/swoole": "0.2.*", "utopia-php/system": "0.4.*", "utopia-php/storage": "0.4.*", - "utopia-php/image": "0.1.*", + "utopia-php/image": "0.2.*", "resque/php-resque": "1.3.6", - "matomo/device-detector": "4.1.0", + "matomo/device-detector": "4.2.2", "dragonmantank/cron-expression": "3.1.0", "influxdb/influxdb-php": "1.15.2", - "phpmailer/phpmailer": "6.3.0", + "phpmailer/phpmailer": "6.4.0", "chillerlan/php-qrcode": "4.3.0", "adhocore/jwt": "1.1.2", - "slickdeals/statsd": "~3.0" + "slickdeals/statsd": "3.0.2" }, "require-dev": { - "swoole/ide-helper": "4.6.2", - "appwrite/sdk-generator": "0.6.3", - "phpunit/phpunit": "9.4.2", - "vimeo/psalm": "4.1.1" + "swoole/ide-helper": "4.6.4", + "appwrite/sdk-generator": "0.7.0", + "phpunit/phpunit": "9.5.4", + "vimeo/psalm": "4.7.0" }, "repositories": [ { @@ -77,10 +77,9 @@ "provide": { "ext-phpiredis": "*" }, - "minimum-stability": "dev", "config": { "platform": { - "php": "7.4" + "php": "8.0" } } } diff --git a/composer.lock b/composer.lock index 16799c29ff..cb2c09885f 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "69222438c59581b58de7052befa6ac00", + "content-hash": "db8c792c684aa44ba5b9808bc7822c21", "packages": [ { "name": "adhocore/jwt", @@ -65,19 +65,20 @@ }, { "name": "appwrite/php-clamav", - "version": "v1.0.1", + "version": "1.1.0", "source": { "type": "git", "url": "https://github.com/appwrite/php-clamav.git", - "reference": "4c13abddfc89d59395da0bd75c18a8eeadc2a542" + "reference": "61d00f24f9e7766fbba233e7b8d09c5475388073" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/appwrite/php-clamav/zipball/4c13abddfc89d59395da0bd75c18a8eeadc2a542", - "reference": "4c13abddfc89d59395da0bd75c18a8eeadc2a542", + "url": "https://api.github.com/repos/appwrite/php-clamav/zipball/61d00f24f9e7766fbba233e7b8d09c5475388073", + "reference": "61d00f24f9e7766fbba233e7b8d09c5475388073", "shasum": "" }, "require": { + "ext-sockets": "*", "php": ">=7.1" }, "require-dev": { @@ -108,9 +109,9 @@ ], "support": { "issues": "https://github.com/appwrite/php-clamav/issues", - "source": "https://github.com/appwrite/php-clamav/tree/master" + "source": "https://github.com/appwrite/php-clamav/tree/1.1.0" }, - "time": "2020-02-29T11:35:01+00:00" + "time": "2020-10-02T05:23:46+00:00" }, { "name": "chillerlan/php-qrcode", @@ -360,16 +361,16 @@ }, { "name": "guzzlehttp/guzzle", - "version": "dev-master", + "version": "7.3.0", "source": { "type": "git", "url": "https://github.com/guzzle/guzzle.git", - "reference": "de6f1e58e735754b888649495ed4cb9ae3b19589" + "reference": "7008573787b430c1c1f650e3722d9bba59967628" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/guzzle/zipball/de6f1e58e735754b888649495ed4cb9ae3b19589", - "reference": "de6f1e58e735754b888649495ed4cb9ae3b19589", + "url": "https://api.github.com/repos/guzzle/guzzle/zipball/7008573787b430c1c1f650e3722d9bba59967628", + "reference": "7008573787b430c1c1f650e3722d9bba59967628", "shasum": "" }, "require": { @@ -394,11 +395,10 @@ "ext-intl": "Required for Internationalized Domain Name (IDN) support", "psr/log": "Required for using the Log middleware" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { - "dev-master": "7.4-dev" + "dev-master": "7.3-dev" } }, "autoload": { @@ -440,7 +440,7 @@ ], "support": { "issues": "https://github.com/guzzle/guzzle/issues", - "source": "https://github.com/guzzle/guzzle/tree/master" + "source": "https://github.com/guzzle/guzzle/tree/7.3.0" }, "funding": [ { @@ -460,11 +460,11 @@ "type": "github" } ], - "time": "2021-03-23T14:07:59+00:00" + "time": "2021-03-23T11:33:13+00:00" }, { "name": "guzzlehttp/promises", - "version": "dev-master", + "version": "1.4.1", "source": { "type": "git", "url": "https://github.com/guzzle/promises.git", @@ -482,7 +482,6 @@ "require-dev": { "symfony/phpunit-bridge": "^4.4 || ^5.1" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -520,47 +519,46 @@ }, { "name": "guzzlehttp/psr7", - "version": "dev-master", + "version": "1.8.1", "source": { "type": "git", "url": "https://github.com/guzzle/psr7.git", - "reference": "c0dcda9f54d145bd4d062a6d15f54931a67732f9" + "reference": "35ea11d335fd638b5882ff1725228b3d35496ab1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/psr7/zipball/c0dcda9f54d145bd4d062a6d15f54931a67732f9", - "reference": "c0dcda9f54d145bd4d062a6d15f54931a67732f9", + "url": "https://api.github.com/repos/guzzle/psr7/zipball/35ea11d335fd638b5882ff1725228b3d35496ab1", + "reference": "35ea11d335fd638b5882ff1725228b3d35496ab1", "shasum": "" }, "require": { - "php": "^7.2.5 || ^8.0", - "psr/http-factory": "^1.0", - "psr/http-message": "^1.0", - "ralouphie/getallheaders": "^3.0" + "php": ">=5.4.0", + "psr/http-message": "~1.0", + "ralouphie/getallheaders": "^2.0.5 || ^3.0.0" }, "provide": { - "psr/http-factory-implementation": "1.0", "psr/http-message-implementation": "1.0" }, "require-dev": { - "bamarni/composer-bin-plugin": "^1.4.1", - "http-interop/http-factory-tests": "^0.9", - "phpunit/phpunit": "^8.5.8 || ^9.3.10" + "ext-zlib": "*", + "phpunit/phpunit": "~4.8.36 || ^5.7.27 || ^6.5.14 || ^7.5.20 || ^8.5.8 || ^9.3.10" }, "suggest": { "laminas/laminas-httphandlerrunner": "Emit PSR-7 responses" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-master": "1.7-dev" } }, "autoload": { "psr-4": { "GuzzleHttp\\Psr7\\": "src/" - } + }, + "files": [ + "src/functions_include.php" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -575,11 +573,6 @@ { "name": "Tobias Schultze", "homepage": "https://github.com/Tobion" - }, - { - "name": "Márk Sági-Kazár", - "email": "mark.sagikazar@gmail.com", - "homepage": "https://sagikazarmark.hu" } ], "description": "PSR-7 message implementation that also provides common utility methods", @@ -595,9 +588,9 @@ ], "support": { "issues": "https://github.com/guzzle/psr7/issues", - "source": "https://github.com/guzzle/psr7/tree/2.0.0-beta1" + "source": "https://github.com/guzzle/psr7/tree/1.8.1" }, - "time": "2021-03-21T17:21:36+00:00" + "time": "2021-03-21T16:25:00+00:00" }, { "name": "influxdb/influxdb-php", @@ -667,16 +660,16 @@ }, { "name": "matomo/device-detector", - "version": "4.1.0", + "version": "4.2.2", "source": { "type": "git", "url": "https://github.com/matomo-org/device-detector.git", - "reference": "6b3facc35e7a465bc4223fddfa5fa88c5b327554" + "reference": "dc270e7645d286d6f01d516a6634aba8b31ad668" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/matomo-org/device-detector/zipball/6b3facc35e7a465bc4223fddfa5fa88c5b327554", - "reference": "6b3facc35e7a465bc4223fddfa5fa88c5b327554", + "url": "https://api.github.com/repos/matomo-org/device-detector/zipball/dc270e7645d286d6f01d516a6634aba8b31ad668", + "reference": "dc270e7645d286d6f01d516a6634aba8b31ad668", "shasum": "" }, "require": { @@ -727,12 +720,12 @@ "useragent" ], "support": { - "forum": "http://forum.matomo.org/", + "forum": "https://forum.matomo.org/", "issues": "https://github.com/matomo-org/device-detector/issues", - "source": "https://github.com/matomo-org/piwik", + "source": "https://github.com/matomo-org/matomo", "wiki": "https://dev.matomo.org/" }, - "time": "2021-01-08T14:14:55+00:00" + "time": "2021-02-26T07:31:42+00:00" }, { "name": "mustangostang/spyc", @@ -786,16 +779,16 @@ }, { "name": "phpmailer/phpmailer", - "version": "v6.3.0", + "version": "v6.4.0", "source": { "type": "git", "url": "https://github.com/PHPMailer/PHPMailer.git", - "reference": "4a08cf4cdd2c38d12ee2b9fa69e5d235f37a6dcb" + "reference": "050d430203105c27c30efd1dce7aa421ad882d01" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/PHPMailer/PHPMailer/zipball/4a08cf4cdd2c38d12ee2b9fa69e5d235f37a6dcb", - "reference": "4a08cf4cdd2c38d12ee2b9fa69e5d235f37a6dcb", + "url": "https://api.github.com/repos/PHPMailer/PHPMailer/zipball/050d430203105c27c30efd1dce7aa421ad882d01", + "reference": "050d430203105c27c30efd1dce7aa421ad882d01", "shasum": "" }, "require": { @@ -813,7 +806,7 @@ "yoast/phpunit-polyfills": "^0.2.0" }, "suggest": { - "ext-mbstring": "Needed to send email in multibyte encoding charset", + "ext-mbstring": "Needed to send email in multibyte encoding charset or decode encoded addresses", "hayageek/oauth2-yahoo": "Needed for Yahoo XOAUTH2 authentication", "league/oauth2-google": "Needed for Google XOAUTH2 authentication", "psr/log": "For optional PSR-3 debug logging", @@ -850,7 +843,7 @@ "description": "PHPMailer is a full-featured email creation and transfer class for PHP", "support": { "issues": "https://github.com/PHPMailer/PHPMailer/issues", - "source": "https://github.com/PHPMailer/PHPMailer/tree/v6.3.0" + "source": "https://github.com/PHPMailer/PHPMailer/tree/v6.4.0" }, "funding": [ { @@ -858,27 +851,26 @@ "type": "github" } ], - "time": "2021-02-19T15:28:08+00:00" + "time": "2021-03-31T20:06:42+00:00" }, { "name": "psr/http-client", - "version": "dev-master", + "version": "1.0.1", "source": { "type": "git", "url": "https://github.com/php-fig/http-client.git", - "reference": "22b2ef5687f43679481615605d7a15c557ce85b1" + "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/http-client/zipball/22b2ef5687f43679481615605d7a15c557ce85b1", - "reference": "22b2ef5687f43679481615605d7a15c557ce85b1", + "url": "https://api.github.com/repos/php-fig/http-client/zipball/2dfb5f6c5eff0e91e20e913f8c5452ed95b86621", + "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621", "shasum": "" }, "require": { "php": "^7.0 || ^8.0", "psr/http-message": "^1.0" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -897,7 +889,7 @@ "authors": [ { "name": "PHP-FIG", - "homepage": "https://www.php-fig.org/" + "homepage": "http://www.php-fig.org/" } ], "description": "Common interface for HTTP clients", @@ -911,82 +903,25 @@ "support": { "source": "https://github.com/php-fig/http-client/tree/master" }, - "time": "2020-09-19T09:12:31+00:00" - }, - { - "name": "psr/http-factory", - "version": "dev-master", - "source": { - "type": "git", - "url": "https://github.com/php-fig/http-factory.git", - "reference": "36fa03d50ff82abcae81860bdaf4ed9a1510c7cd" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/php-fig/http-factory/zipball/36fa03d50ff82abcae81860bdaf4ed9a1510c7cd", - "reference": "36fa03d50ff82abcae81860bdaf4ed9a1510c7cd", - "shasum": "" - }, - "require": { - "php": ">=7.0.0", - "psr/http-message": "^1.0" - }, - "default-branch": true, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Psr\\Http\\Message\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "https://www.php-fig.org/" - } - ], - "description": "Common interfaces for PSR-7 HTTP message factories", - "keywords": [ - "factory", - "http", - "message", - "psr", - "psr-17", - "psr-7", - "request", - "response" - ], - "support": { - "source": "https://github.com/php-fig/http-factory/tree/master" - }, - "time": "2020-09-17T16:52:55+00:00" + "time": "2020-06-29T06:28:15+00:00" }, { "name": "psr/http-message", - "version": "dev-master", + "version": "1.0.1", "source": { "type": "git", "url": "https://github.com/php-fig/http-message.git", - "reference": "efd67d1dc14a7ef4fc4e518e7dee91c271d524e4" + "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/http-message/zipball/efd67d1dc14a7ef4fc4e518e7dee91c271d524e4", - "reference": "efd67d1dc14a7ef4fc4e518e7dee91c271d524e4", + "url": "https://api.github.com/repos/php-fig/http-message/zipball/f6561bf28d520154e4b0ec72be95418abe6d9363", + "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363", "shasum": "" }, "require": { "php": ">=5.3.0" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -1021,26 +956,25 @@ "support": { "source": "https://github.com/php-fig/http-message/tree/master" }, - "time": "2019-08-29T13:16:46+00:00" + "time": "2016-08-06T14:39:51+00:00" }, { "name": "psr/log", - "version": "dev-master", + "version": "1.1.3", "source": { "type": "git", "url": "https://github.com/php-fig/log.git", - "reference": "a18c1e692e02b84abbafe4856c3cd7cc6903908c" + "reference": "0f73288fd15629204f9d42b7055f72dacbe811fc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/log/zipball/a18c1e692e02b84abbafe4856c3cd7cc6903908c", - "reference": "a18c1e692e02b84abbafe4856c3cd7cc6903908c", + "url": "https://api.github.com/repos/php-fig/log/zipball/0f73288fd15629204f9d42b7055f72dacbe811fc", + "reference": "0f73288fd15629204f9d42b7055f72dacbe811fc", "shasum": "" }, "require": { "php": ">=5.3.0" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -1059,7 +993,7 @@ "authors": [ { "name": "PHP-FIG", - "homepage": "https://www.php-fig.org/" + "homepage": "http://www.php-fig.org/" } ], "description": "Common interface for logging libraries", @@ -1070,9 +1004,9 @@ "psr-3" ], "support": { - "source": "https://github.com/php-fig/log/tree/master" + "source": "https://github.com/php-fig/log/tree/1.1.3" }, - "time": "2021-03-02T15:02:34+00:00" + "time": "2020-03-23T09:12:05+00:00" }, { "name": "ralouphie/getallheaders", @@ -1256,7 +1190,7 @@ }, { "name": "symfony/polyfill-ctype", - "version": "dev-main", + "version": "v1.22.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", @@ -1274,7 +1208,6 @@ "suggest": { "ext-ctype": "For best performance" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -1651,24 +1584,23 @@ }, { "name": "utopia-php/domains", - "version": "0.2.3", + "version": "v1.1.0", "source": { "type": "git", "url": "https://github.com/utopia-php/domains.git", - "reference": "6c9b3706b0df4e0150a1f9062321ff114270a643" + "reference": "1665e1d9932afa3be63b5c1e0dcfe01fe77d8e73" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/domains/zipball/6c9b3706b0df4e0150a1f9062321ff114270a643", - "reference": "6c9b3706b0df4e0150a1f9062321ff114270a643", + "url": "https://api.github.com/repos/utopia-php/domains/zipball/1665e1d9932afa3be63b5c1e0dcfe01fe77d8e73", + "reference": "1665e1d9932afa3be63b5c1e0dcfe01fe77d8e73", "shasum": "" }, "require": { "php": ">=7.1" }, "require-dev": { - "phpunit/phpunit": "^9.3", - "vimeo/psalm": "4.0.1" + "phpunit/phpunit": "^7.0" }, "type": "library", "autoload": { @@ -1700,9 +1632,9 @@ ], "support": { "issues": "https://github.com/utopia-php/domains/issues", - "source": "https://github.com/utopia-php/domains/tree/0.2.3" + "source": "https://github.com/utopia-php/domains/tree/master" }, - "time": "2020-10-23T09:59:51+00:00" + "time": "2020-02-23T07:40:02+00:00" }, { "name": "utopia-php/framework", @@ -1755,16 +1687,16 @@ }, { "name": "utopia-php/image", - "version": "0.1.0", + "version": "0.2.0", "source": { "type": "git", "url": "https://github.com/utopia-php/image.git", - "reference": "66e38db211b1d6fe93de09d82606641e0f996e42" + "reference": "3b22910b0257657ba40e853918cb7c9d19fba125" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/image/zipball/66e38db211b1d6fe93de09d82606641e0f996e42", - "reference": "66e38db211b1d6fe93de09d82606641e0f996e42", + "url": "https://api.github.com/repos/utopia-php/image/zipball/3b22910b0257657ba40e853918cb7c9d19fba125", + "reference": "3b22910b0257657ba40e853918cb7c9d19fba125", "shasum": "" }, "require": { @@ -1802,9 +1734,9 @@ ], "support": { "issues": "https://github.com/utopia-php/image/issues", - "source": "https://github.com/utopia-php/image/tree/0.1.0" + "source": "https://github.com/utopia-php/image/tree/0.2.0" }, - "time": "2021-02-19T05:09:46+00:00" + "time": "2021-03-18T04:49:59+00:00" }, { "name": "utopia-php/locale", @@ -1912,20 +1844,20 @@ }, { "name": "utopia-php/registry", - "version": "0.2.4", + "version": "0.4.0", "source": { "type": "git", "url": "https://github.com/utopia-php/registry.git", - "reference": "428a94f1a36147e7b7221e778c01e1be08db2893" + "reference": "7aebbc6c5f3f04ff7a35ac3dad39fa91c9bd7c2d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/registry/zipball/428a94f1a36147e7b7221e778c01e1be08db2893", - "reference": "428a94f1a36147e7b7221e778c01e1be08db2893", + "url": "https://api.github.com/repos/utopia-php/registry/zipball/7aebbc6c5f3f04ff7a35ac3dad39fa91c9bd7c2d", + "reference": "7aebbc6c5f3f04ff7a35ac3dad39fa91c9bd7c2d", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=7.4" }, "require-dev": { "phpunit/phpunit": "^9.3", @@ -1958,9 +1890,9 @@ ], "support": { "issues": "https://github.com/utopia-php/registry/issues", - "source": "https://github.com/utopia-php/registry/tree/0.2.4" + "source": "https://github.com/utopia-php/registry/tree/0.4.0" }, - "time": "2020-10-24T08:51:37+00:00" + "time": "2021-03-10T06:50:09+00:00" }, { "name": "utopia-php/storage", @@ -2127,30 +2059,35 @@ }, { "name": "webmozart/assert", - "version": "1.9.1", + "version": "1.10.0", "source": { "type": "git", "url": "https://github.com/webmozarts/assert.git", - "reference": "bafc69caeb4d49c39fd0779086c03a3738cbb389" + "reference": "6964c76c7804814a842473e0c8fd15bab0f18e25" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/webmozarts/assert/zipball/bafc69caeb4d49c39fd0779086c03a3738cbb389", - "reference": "bafc69caeb4d49c39fd0779086c03a3738cbb389", + "url": "https://api.github.com/repos/webmozarts/assert/zipball/6964c76c7804814a842473e0c8fd15bab0f18e25", + "reference": "6964c76c7804814a842473e0c8fd15bab0f18e25", "shasum": "" }, "require": { - "php": "^5.3.3 || ^7.0 || ^8.0", + "php": "^7.2 || ^8.0", "symfony/polyfill-ctype": "^1.8" }, "conflict": { "phpstan/phpstan": "<0.12.20", - "vimeo/psalm": "<3.9.1" + "vimeo/psalm": "<4.6.1 || 4.6.2" }, "require-dev": { - "phpunit/phpunit": "^4.8.36 || ^7.5.13" + "phpunit/phpunit": "^8.5.13" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.10-dev" + } + }, "autoload": { "psr-4": { "Webmozart\\Assert\\": "src/" @@ -2174,39 +2111,38 @@ ], "support": { "issues": "https://github.com/webmozarts/assert/issues", - "source": "https://github.com/webmozarts/assert/tree/1.9.1" + "source": "https://github.com/webmozarts/assert/tree/1.10.0" }, - "time": "2020-07-08T17:02:28+00:00" + "time": "2021-03-09T10:59:23+00:00" } ], "packages-dev": [ { "name": "amphp/amp", - "version": "dev-master", + "version": "v2.5.2", "source": { "type": "git", "url": "https://github.com/amphp/amp.git", - "reference": "7d4bbc6e0b47c6bb39b6cce1a4b5942e0c5125fb" + "reference": "efca2b32a7580087adb8aabbff6be1dc1bb924a9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/amphp/amp/zipball/7d4bbc6e0b47c6bb39b6cce1a4b5942e0c5125fb", - "reference": "7d4bbc6e0b47c6bb39b6cce1a4b5942e0c5125fb", + "url": "https://api.github.com/repos/amphp/amp/zipball/efca2b32a7580087adb8aabbff6be1dc1bb924a9", + "reference": "efca2b32a7580087adb8aabbff6be1dc1bb924a9", "shasum": "" }, "require": { - "php": ">=7.1" + "php": ">=7" }, "require-dev": { "amphp/php-cs-fixer-config": "dev-master", "amphp/phpunit-util": "^1", "ext-json": "*", "jetbrains/phpstorm-stubs": "^2019.3", - "phpunit/phpunit": "^7 | ^8 | ^9", + "phpunit/phpunit": "^6.0.9 | ^7", "psalm/phar": "^3.11@dev", "react/promise": "^2" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -2260,7 +2196,7 @@ "support": { "irc": "irc://irc.freenode.org/amphp", "issues": "https://github.com/amphp/amp/issues", - "source": "https://github.com/amphp/amp/tree/master" + "source": "https://github.com/amphp/amp/tree/v2.5.2" }, "funding": [ { @@ -2268,20 +2204,20 @@ "type": "github" } ], - "time": "2021-01-13T19:16:50+00:00" + "time": "2021-01-10T17:06:37+00:00" }, { "name": "amphp/byte-stream", - "version": "dev-master", + "version": "v1.8.1", "source": { "type": "git", "url": "https://github.com/amphp/byte-stream.git", - "reference": "f813a658f0446192c5e17f96727070ee9342b93a" + "reference": "acbd8002b3536485c997c4e019206b3f10ca15bd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/amphp/byte-stream/zipball/f813a658f0446192c5e17f96727070ee9342b93a", - "reference": "f813a658f0446192c5e17f96727070ee9342b93a", + "url": "https://api.github.com/repos/amphp/byte-stream/zipball/acbd8002b3536485c997c4e019206b3f10ca15bd", + "reference": "acbd8002b3536485c997c4e019206b3f10ca15bd", "shasum": "" }, "require": { @@ -2296,7 +2232,6 @@ "phpunit/phpunit": "^6 || ^7 || ^8", "psalm/phar": "^3.11.4" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -2338,7 +2273,7 @@ "support": { "irc": "irc://irc.freenode.org/amphp", "issues": "https://github.com/amphp/byte-stream/issues", - "source": "https://github.com/amphp/byte-stream/tree/master" + "source": "https://github.com/amphp/byte-stream/tree/v1.8.1" }, "funding": [ { @@ -2346,15 +2281,15 @@ "type": "github" } ], - "time": "2020-08-30T19:23:04+00:00" + "time": "2021-03-30T17:13:30+00:00" }, { "name": "appwrite/sdk-generator", - "version": "0.6.3", + "version": "0.7.0", "source": { "type": "git", "url": "https://github.com/appwrite/sdk-generator", - "reference": "583248c57c5bcbd9c74f8312cc7fc3ab6cda51a3" + "reference": "12a6a4b723137d5449c84ee2915b1ab3586e2162" }, "require": { "ext-curl": "*", @@ -2384,20 +2319,20 @@ } ], "description": "Appwrite PHP library for generating API SDKs for multiple programming languages and platforms", - "time": "2021-03-07T08:45:05+00:00" + "time": "2021-03-23T09:26:18+00:00" }, { "name": "composer/package-versions-deprecated", - "version": "dev-master", + "version": "1.11.99.1", "source": { "type": "git", "url": "https://github.com/composer/package-versions-deprecated.git", - "reference": "f921205948ab93bb19f86327c793a81edb62f236" + "reference": "7413f0b55a051e89485c5cb9f765fe24bb02a7b6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/package-versions-deprecated/zipball/f921205948ab93bb19f86327c793a81edb62f236", - "reference": "f921205948ab93bb19f86327c793a81edb62f236", + "url": "https://api.github.com/repos/composer/package-versions-deprecated/zipball/7413f0b55a051e89485c5cb9f765fe24bb02a7b6", + "reference": "7413f0b55a051e89485c5cb9f765fe24bb02a7b6", "shasum": "" }, "require": { @@ -2412,7 +2347,6 @@ "ext-zip": "^1.13", "phpunit/phpunit": "^6.5 || ^7" }, - "default-branch": true, "type": "composer-plugin", "extra": { "class": "PackageVersions\\Installer", @@ -2442,7 +2376,7 @@ "description": "Composer plugin that provides efficient querying for installed package versions (no runtime IO)", "support": { "issues": "https://github.com/composer/package-versions-deprecated/issues", - "source": "https://github.com/composer/package-versions-deprecated/tree/master" + "source": "https://github.com/composer/package-versions-deprecated/tree/1.11.99.1" }, "funding": [ { @@ -2458,20 +2392,20 @@ "type": "tidelift" } ], - "time": "2020-12-27T20:11:05+00:00" + "time": "2020-11-11T10:22:58+00:00" }, { "name": "composer/semver", - "version": "dev-main", + "version": "3.2.4", "source": { "type": "git", "url": "https://github.com/composer/semver.git", - "reference": "dd61cb4efbd0cff1700b217faf24ce596af4fc4e" + "reference": "a02fdf930a3c1c3ed3a49b5f63859c0c20e10464" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/semver/zipball/dd61cb4efbd0cff1700b217faf24ce596af4fc4e", - "reference": "dd61cb4efbd0cff1700b217faf24ce596af4fc4e", + "url": "https://api.github.com/repos/composer/semver/zipball/a02fdf930a3c1c3ed3a49b5f63859c0c20e10464", + "reference": "a02fdf930a3c1c3ed3a49b5f63859c0c20e10464", "shasum": "" }, "require": { @@ -2481,7 +2415,6 @@ "phpstan/phpstan": "^0.12.54", "symfony/phpunit-bridge": "^4.2 || ^5" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -2524,7 +2457,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/semver/issues", - "source": "https://github.com/composer/semver/tree/main" + "source": "https://github.com/composer/semver/tree/3.2.4" }, "funding": [ { @@ -2540,20 +2473,20 @@ "type": "tidelift" } ], - "time": "2020-12-10T07:55:43+00:00" + "time": "2020-11-13T08:59:24+00:00" }, { "name": "composer/xdebug-handler", - "version": "1.4.5", + "version": "1.4.6", "source": { "type": "git", "url": "https://github.com/composer/xdebug-handler.git", - "reference": "f28d44c286812c714741478d968104c5e604a1d4" + "reference": "f27e06cd9675801df441b3656569b328e04aa37c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/f28d44c286812c714741478d968104c5e604a1d4", - "reference": "f28d44c286812c714741478d968104c5e604a1d4", + "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/f27e06cd9675801df441b3656569b328e04aa37c", + "reference": "f27e06cd9675801df441b3656569b328e04aa37c", "shasum": "" }, "require": { @@ -2561,7 +2494,8 @@ "psr/log": "^1.0" }, "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.7 || 6.5 - 8" + "phpstan/phpstan": "^0.12.55", + "symfony/phpunit-bridge": "^4.2 || ^5" }, "type": "library", "autoload": { @@ -2587,7 +2521,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/xdebug-handler/issues", - "source": "https://github.com/composer/xdebug-handler/tree/1.4.5" + "source": "https://github.com/composer/xdebug-handler/tree/1.4.6" }, "funding": [ { @@ -2603,7 +2537,7 @@ "type": "tidelift" } ], - "time": "2020-11-13T08:04:11+00:00" + "time": "2021-03-25T17:01:18+00:00" }, { "name": "dnoegel/php-xdg-base-dir", @@ -2644,16 +2578,16 @@ }, { "name": "doctrine/instantiator", - "version": "1.5.x-dev", + "version": "1.4.0", "source": { "type": "git", "url": "https://github.com/doctrine/instantiator.git", - "reference": "6410c4b8352cb64218641457cef64997e6b784fb" + "reference": "d56bf6102915de5702778fe20f2de3b2fe570b5b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/6410c4b8352cb64218641457cef64997e6b784fb", - "reference": "6410c4b8352cb64218641457cef64997e6b784fb", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/d56bf6102915de5702778fe20f2de3b2fe570b5b", + "reference": "d56bf6102915de5702778fe20f2de3b2fe570b5b", "shasum": "" }, "require": { @@ -2693,7 +2627,7 @@ ], "support": { "issues": "https://github.com/doctrine/instantiator/issues", - "source": "https://github.com/doctrine/instantiator/tree/1.4.x" + "source": "https://github.com/doctrine/instantiator/tree/1.4.0" }, "funding": [ { @@ -2709,7 +2643,7 @@ "type": "tidelift" } ], - "time": "2020-11-10T19:05:51+00:00" + "time": "2020-11-10T18:47:58+00:00" }, { "name": "felixfbecker/advanced-json-rpc", @@ -2758,7 +2692,7 @@ }, { "name": "felixfbecker/language-server-protocol", - "version": "dev-master", + "version": "1.5.1", "source": { "type": "git", "url": "https://github.com/felixfbecker/php-language-server-protocol.git", @@ -2778,7 +2712,6 @@ "squizlabs/php_codesniffer": "^3.1", "vimeo/psalm": "^4.0" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -2946,7 +2879,7 @@ }, { "name": "myclabs/deep-copy", - "version": "1.x-dev", + "version": "1.10.2", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", @@ -2969,7 +2902,6 @@ "doctrine/common": "^2.6", "phpunit/phpunit": "^7.1" }, - "default-branch": true, "type": "library", "autoload": { "psr-4": { @@ -3165,7 +3097,7 @@ }, { "name": "phar-io/manifest", - "version": "dev-master", + "version": "2.0.1", "source": { "type": "git", "url": "https://github.com/phar-io/manifest.git", @@ -3184,7 +3116,6 @@ "phar-io/version": "^3.0.1", "php": "^7.2 || ^8.0" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -3220,7 +3151,7 @@ "description": "Component for reading phar.io manifest information from a PHP Archive (PHAR)", "support": { "issues": "https://github.com/phar-io/manifest/issues", - "source": "https://github.com/phar-io/manifest/tree/2.0.1" + "source": "https://github.com/phar-io/manifest/tree/master" }, "time": "2020-06-27T14:33:11+00:00" }, @@ -3277,26 +3208,25 @@ }, { "name": "phpdocumentor/reflection-common", - "version": "dev-master", + "version": "2.2.0", "source": { "type": "git", "url": "https://github.com/phpDocumentor/ReflectionCommon.git", - "reference": "cf8df60735d98fd18070b7cab0019ba0831e219c" + "reference": "1d01c49d4ed62f25aa84a747ad35d5a16924662b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionCommon/zipball/cf8df60735d98fd18070b7cab0019ba0831e219c", - "reference": "cf8df60735d98fd18070b7cab0019ba0831e219c", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionCommon/zipball/1d01c49d4ed62f25aa84a747ad35d5a16924662b", + "reference": "1d01c49d4ed62f25aa84a747ad35d5a16924662b", "shasum": "" }, "require": { - "php": ">=7.1" + "php": "^7.2 || ^8.0" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.x-dev" + "dev-2.x": "2.x-dev" } }, "autoload": { @@ -3325,22 +3255,22 @@ ], "support": { "issues": "https://github.com/phpDocumentor/ReflectionCommon/issues", - "source": "https://github.com/phpDocumentor/ReflectionCommon/tree/master" + "source": "https://github.com/phpDocumentor/ReflectionCommon/tree/2.x" }, - "time": "2020-06-19T17:42:03+00:00" + "time": "2020-06-27T09:03:43+00:00" }, { "name": "phpdocumentor/reflection-docblock", - "version": "dev-master", + "version": "5.2.2", "source": { "type": "git", "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "f8d350d8514ff60b5993dd0121c62299480c989c" + "reference": "069a785b2141f5bcf49f3e353548dc1cce6df556" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/f8d350d8514ff60b5993dd0121c62299480c989c", - "reference": "f8d350d8514ff60b5993dd0121c62299480c989c", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/069a785b2141f5bcf49f3e353548dc1cce6df556", + "reference": "069a785b2141f5bcf49f3e353548dc1cce6df556", "shasum": "" }, "require": { @@ -3353,7 +3283,6 @@ "require-dev": { "mockery/mockery": "~1.3.2" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -3384,20 +3313,20 @@ "issues": "https://github.com/phpDocumentor/ReflectionDocBlock/issues", "source": "https://github.com/phpDocumentor/ReflectionDocBlock/tree/master" }, - "time": "2021-03-07T11:12:25+00:00" + "time": "2020-09-03T19:13:55+00:00" }, { "name": "phpdocumentor/type-resolver", - "version": "1.x-dev", + "version": "1.4.0", "source": { "type": "git", "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "6759f2268deb9f329812679e9dcb2d0083b2a30b" + "reference": "6a467b8989322d92aa1c8bf2bebcc6e5c2ba55c0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/6759f2268deb9f329812679e9dcb2d0083b2a30b", - "reference": "6759f2268deb9f329812679e9dcb2d0083b2a30b", + "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/6a467b8989322d92aa1c8bf2bebcc6e5c2ba55c0", + "reference": "6a467b8989322d92aa1c8bf2bebcc6e5c2ba55c0", "shasum": "" }, "require": { @@ -3407,7 +3336,6 @@ "require-dev": { "ext-tokenizer": "*" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -3432,9 +3360,9 @@ "description": "A PSR-5 based resolver of Class names, Types and Structural Element Names", "support": { "issues": "https://github.com/phpDocumentor/TypeResolver/issues", - "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.x" + "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.4.0" }, - "time": "2021-02-02T21:09:27+00:00" + "time": "2020-09-17T18:55:26+00:00" }, { "name": "phpspec/prophecy", @@ -3505,16 +3433,16 @@ }, { "name": "phpunit/php-code-coverage", - "version": "9.2.x-dev", + "version": "9.2.6", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "ad069801f3d0cdb7102e58afd5f9f32834ec7160" + "reference": "f6293e1b30a2354e8428e004689671b83871edde" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/ad069801f3d0cdb7102e58afd5f9f32834ec7160", - "reference": "ad069801f3d0cdb7102e58afd5f9f32834ec7160", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f6293e1b30a2354e8428e004689671b83871edde", + "reference": "f6293e1b30a2354e8428e004689671b83871edde", "shasum": "" }, "require": { @@ -3570,7 +3498,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.6" }, "funding": [ { @@ -3578,20 +3506,20 @@ "type": "github" } ], - "time": "2021-02-08T09:55:27+00:00" + "time": "2021-03-28T07:26:59+00:00" }, { "name": "phpunit/php-file-iterator", - "version": "dev-master", + "version": "3.0.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "b2ce4cf415b9989fac88e8c27c39b5ba2faad72b" + "reference": "aa4be8575f26070b100fccb67faabb28f21f66f8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/b2ce4cf415b9989fac88e8c27c39b5ba2faad72b", - "reference": "b2ce4cf415b9989fac88e8c27c39b5ba2faad72b", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/aa4be8575f26070b100fccb67faabb28f21f66f8", + "reference": "aa4be8575f26070b100fccb67faabb28f21f66f8", "shasum": "" }, "require": { @@ -3600,7 +3528,6 @@ "require-dev": { "phpunit/phpunit": "^9.3" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -3631,7 +3558,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", - "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/master" + "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/3.0.5" }, "funding": [ { @@ -3639,20 +3566,20 @@ "type": "github" } ], - "time": "2021-03-17T06:17:19+00:00" + "time": "2020-09-28T05:57:25+00:00" }, { "name": "phpunit/php-invoker", - "version": "dev-master", + "version": "3.1.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-invoker.git", - "reference": "e2905d5648ac5e9bd0aa85b50d240e5890f76493" + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/e2905d5648ac5e9bd0aa85b50d240e5890f76493", - "reference": "e2905d5648ac5e9bd0aa85b50d240e5890f76493", + "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/5a10147d0aaf65b58940a0b72f71c9ac0423cc67", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67", "shasum": "" }, "require": { @@ -3665,7 +3592,6 @@ "suggest": { "ext-pcntl": "*" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -3695,7 +3621,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-invoker/issues", - "source": "https://github.com/sebastianbergmann/php-invoker/tree/master" + "source": "https://github.com/sebastianbergmann/php-invoker/tree/3.1.1" }, "funding": [ { @@ -3703,20 +3629,20 @@ "type": "github" } ], - "time": "2021-03-17T06:17:27+00:00" + "time": "2020-09-28T05:58:55+00:00" }, { "name": "phpunit/php-text-template", - "version": "dev-master", + "version": "2.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "e6a2483ffd3659d723996fb8b2ca638244b87e7c" + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/e6a2483ffd3659d723996fb8b2ca638244b87e7c", - "reference": "e6a2483ffd3659d723996fb8b2ca638244b87e7c", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", "shasum": "" }, "require": { @@ -3725,7 +3651,6 @@ "require-dev": { "phpunit/phpunit": "^9.3" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -3755,7 +3680,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-text-template/issues", - "source": "https://github.com/sebastianbergmann/php-text-template/tree/master" + "source": "https://github.com/sebastianbergmann/php-text-template/tree/2.0.4" }, "funding": [ { @@ -3763,20 +3688,20 @@ "type": "github" } ], - "time": "2021-03-17T06:17:59+00:00" + "time": "2020-10-26T05:33:50+00:00" }, { "name": "phpunit/php-timer", - "version": "dev-master", + "version": "5.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "c0187813193d3709a455b94916bbee2881a1c6e3" + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/c0187813193d3709a455b94916bbee2881a1c6e3", - "reference": "c0187813193d3709a455b94916bbee2881a1c6e3", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", "shasum": "" }, "require": { @@ -3785,7 +3710,6 @@ "require-dev": { "phpunit/phpunit": "^9.3" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -3815,7 +3739,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-timer/issues", - "source": "https://github.com/sebastianbergmann/php-timer/tree/master" + "source": "https://github.com/sebastianbergmann/php-timer/tree/5.0.3" }, "funding": [ { @@ -3823,20 +3747,20 @@ "type": "github" } ], - "time": "2021-03-17T06:17:35+00:00" + "time": "2020-10-26T13:16:10+00:00" }, { "name": "phpunit/phpunit", - "version": "9.4.2", + "version": "9.5.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "3866b2eeeed21b1b099c4bc0b7a1690ac6fd5baa" + "reference": "c73c6737305e779771147af66c96ca6a7ed8a741" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/3866b2eeeed21b1b099c4bc0b7a1690ac6fd5baa", - "reference": "3866b2eeeed21b1b099c4bc0b7a1690ac6fd5baa", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c73c6737305e779771147af66c96ca6a7ed8a741", + "reference": "c73c6737305e779771147af66c96ca6a7ed8a741", "shasum": "" }, "require": { @@ -3852,7 +3776,7 @@ "phar-io/version": "^3.0.2", "php": ">=7.3", "phpspec/prophecy": "^1.12.1", - "phpunit/php-code-coverage": "^9.2", + "phpunit/php-code-coverage": "^9.2.3", "phpunit/php-file-iterator": "^3.0.5", "phpunit/php-invoker": "^3.1.1", "phpunit/php-text-template": "^2.0.3", @@ -3883,7 +3807,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "9.4-dev" + "dev-master": "9.5-dev" } }, "autoload": { @@ -3914,7 +3838,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.4.2" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.4" }, "funding": [ { @@ -3926,11 +3850,11 @@ "type": "github" } ], - "time": "2020-10-19T09:23:29+00:00" + "time": "2021-03-23T07:16:29+00:00" }, { "name": "psr/container", - "version": "1.1.x-dev", + "version": "1.1.1", "source": { "type": "git", "url": "https://github.com/php-fig/container.git", @@ -3972,22 +3896,22 @@ ], "support": { "issues": "https://github.com/php-fig/container/issues", - "source": "https://github.com/php-fig/container/tree/1.1.x" + "source": "https://github.com/php-fig/container/tree/1.1.1" }, "time": "2021-03-05T17:36:06+00:00" }, { "name": "sebastian/cli-parser", - "version": "dev-master", + "version": "1.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/cli-parser.git", - "reference": "845853b8c553f6b61d9a708b8f26066806bcc7dd" + "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/845853b8c553f6b61d9a708b8f26066806bcc7dd", - "reference": "845853b8c553f6b61d9a708b8f26066806bcc7dd", + "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/442e7c7e687e42adc03470c7b668bc4b2402c0b2", + "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2", "shasum": "" }, "require": { @@ -3996,7 +3920,6 @@ "require-dev": { "phpunit/phpunit": "^9.3" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -4023,7 +3946,7 @@ "homepage": "https://github.com/sebastianbergmann/cli-parser", "support": { "issues": "https://github.com/sebastianbergmann/cli-parser/issues", - "source": "https://github.com/sebastianbergmann/cli-parser/tree/master" + "source": "https://github.com/sebastianbergmann/cli-parser/tree/1.0.1" }, "funding": [ { @@ -4031,7 +3954,7 @@ "type": "github" } ], - "time": "2021-03-17T06:18:24+00:00" + "time": "2020-09-28T06:08:49+00:00" }, { "name": "sebastian/code-unit", @@ -4091,16 +4014,16 @@ }, { "name": "sebastian/code-unit-reverse-lookup", - "version": "dev-master", + "version": "2.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", - "reference": "ab4d610891809670894a4fc260c17e5d5960ba4c" + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/ab4d610891809670894a4fc260c17e5d5960ba4c", - "reference": "ab4d610891809670894a4fc260c17e5d5960ba4c", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", "shasum": "" }, "require": { @@ -4109,7 +4032,6 @@ "require-dev": { "phpunit/phpunit": "^9.3" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -4135,7 +4057,7 @@ "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", "support": { "issues": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/issues", - "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/master" + "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/2.0.3" }, "funding": [ { @@ -4143,20 +4065,20 @@ "type": "github" } ], - "time": "2021-03-17T06:16:16+00:00" + "time": "2020-09-28T05:30:19+00:00" }, { "name": "sebastian/comparator", - "version": "dev-master", + "version": "4.0.6", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "d3d66b8faa86ac57e1236d576ad003f73097c9cd" + "reference": "55f4261989e546dc112258c7a75935a81a7ce382" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/d3d66b8faa86ac57e1236d576ad003f73097c9cd", - "reference": "d3d66b8faa86ac57e1236d576ad003f73097c9cd", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/55f4261989e546dc112258c7a75935a81a7ce382", + "reference": "55f4261989e546dc112258c7a75935a81a7ce382", "shasum": "" }, "require": { @@ -4167,7 +4089,6 @@ "require-dev": { "phpunit/phpunit": "^9.3" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -4210,7 +4131,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/comparator/issues", - "source": "https://github.com/sebastianbergmann/comparator/tree/master" + "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.6" }, "funding": [ { @@ -4218,7 +4139,7 @@ "type": "github" } ], - "time": "2021-03-17T06:16:24+00:00" + "time": "2020-10-26T15:49:45+00:00" }, { "name": "sebastian/complexity", @@ -4279,16 +4200,16 @@ }, { "name": "sebastian/diff", - "version": "dev-master", + "version": "4.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "e81849c6dfbe34442b4685fa457fd6f012370e54" + "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/e81849c6dfbe34442b4685fa457fd6f012370e54", - "reference": "e81849c6dfbe34442b4685fa457fd6f012370e54", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/3461e3fccc7cfdfc2720be910d3bd73c69be590d", + "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d", "shasum": "" }, "require": { @@ -4298,7 +4219,6 @@ "phpunit/phpunit": "^9.3", "symfony/process": "^4.2 || ^5" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -4334,7 +4254,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/diff/issues", - "source": "https://github.com/sebastianbergmann/diff/tree/master" + "source": "https://github.com/sebastianbergmann/diff/tree/4.0.4" }, "funding": [ { @@ -4342,20 +4262,20 @@ "type": "github" } ], - "time": "2021-03-17T06:16:31+00:00" + "time": "2020-10-26T13:10:38+00:00" }, { "name": "sebastian/environment", - "version": "dev-master", + "version": "5.1.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "c25633688d84a9f8694989223479051b5a8a23e7" + "reference": "388b6ced16caa751030f6a69e588299fa09200ac" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/c25633688d84a9f8694989223479051b5a8a23e7", - "reference": "c25633688d84a9f8694989223479051b5a8a23e7", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/388b6ced16caa751030f6a69e588299fa09200ac", + "reference": "388b6ced16caa751030f6a69e588299fa09200ac", "shasum": "" }, "require": { @@ -4367,7 +4287,6 @@ "suggest": { "ext-posix": "*" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -4398,7 +4317,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/environment/issues", - "source": "https://github.com/sebastianbergmann/environment/tree/master" + "source": "https://github.com/sebastianbergmann/environment/tree/5.1.3" }, "funding": [ { @@ -4406,20 +4325,20 @@ "type": "github" } ], - "time": "2021-03-17T06:16:40+00:00" + "time": "2020-09-28T05:52:38+00:00" }, { "name": "sebastian/exporter", - "version": "dev-master", + "version": "4.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "9119858d42f3963d01b737f029bb90f8464fd0ca" + "reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/9119858d42f3963d01b737f029bb90f8464fd0ca", - "reference": "9119858d42f3963d01b737f029bb90f8464fd0ca", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/d89cc98761b8cb5a1a235a6b703ae50d34080e65", + "reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65", "shasum": "" }, "require": { @@ -4430,7 +4349,6 @@ "ext-mbstring": "*", "phpunit/phpunit": "^9.3" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -4476,7 +4394,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/exporter/issues", - "source": "https://github.com/sebastianbergmann/exporter/tree/master" + "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.3" }, "funding": [ { @@ -4484,20 +4402,20 @@ "type": "github" } ], - "time": "2021-03-17T06:16:48+00:00" + "time": "2020-09-28T05:24:23+00:00" }, { "name": "sebastian/global-state", - "version": "dev-master", + "version": "5.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "fe610de5530e3d29007134f76ee8dc79581a607d" + "reference": "a90ccbddffa067b51f574dea6eb25d5680839455" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/fe610de5530e3d29007134f76ee8dc79581a607d", - "reference": "fe610de5530e3d29007134f76ee8dc79581a607d", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/a90ccbddffa067b51f574dea6eb25d5680839455", + "reference": "a90ccbddffa067b51f574dea6eb25d5680839455", "shasum": "" }, "require": { @@ -4512,7 +4430,6 @@ "suggest": { "ext-uopz": "*" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -4541,7 +4458,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/global-state/issues", - "source": "https://github.com/sebastianbergmann/global-state/tree/master" + "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.2" }, "funding": [ { @@ -4549,7 +4466,7 @@ "type": "github" } ], - "time": "2021-03-17T06:16:56+00:00" + "time": "2020-10-26T15:55:19+00:00" }, { "name": "sebastian/lines-of-code", @@ -4610,16 +4527,16 @@ }, { "name": "sebastian/object-enumerator", - "version": "dev-master", + "version": "4.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "01ab82e49081de59e2da70c351d5f698c77c33c5" + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/01ab82e49081de59e2da70c351d5f698c77c33c5", - "reference": "01ab82e49081de59e2da70c351d5f698c77c33c5", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/5c9eeac41b290a3712d88851518825ad78f45c71", + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71", "shasum": "" }, "require": { @@ -4630,7 +4547,6 @@ "require-dev": { "phpunit/phpunit": "^9.3" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -4656,7 +4572,7 @@ "homepage": "https://github.com/sebastianbergmann/object-enumerator/", "support": { "issues": "https://github.com/sebastianbergmann/object-enumerator/issues", - "source": "https://github.com/sebastianbergmann/object-enumerator/tree/master" + "source": "https://github.com/sebastianbergmann/object-enumerator/tree/4.0.4" }, "funding": [ { @@ -4664,20 +4580,20 @@ "type": "github" } ], - "time": "2021-03-17T06:17:03+00:00" + "time": "2020-10-26T13:12:34+00:00" }, { "name": "sebastian/object-reflector", - "version": "dev-master", + "version": "2.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-reflector.git", - "reference": "7ed67aee59862b40785138f0203e86f1fde1b93a" + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/7ed67aee59862b40785138f0203e86f1fde1b93a", - "reference": "7ed67aee59862b40785138f0203e86f1fde1b93a", + "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", "shasum": "" }, "require": { @@ -4686,7 +4602,6 @@ "require-dev": { "phpunit/phpunit": "^9.3" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -4712,7 +4627,7 @@ "homepage": "https://github.com/sebastianbergmann/object-reflector/", "support": { "issues": "https://github.com/sebastianbergmann/object-reflector/issues", - "source": "https://github.com/sebastianbergmann/object-reflector/tree/master" + "source": "https://github.com/sebastianbergmann/object-reflector/tree/2.0.4" }, "funding": [ { @@ -4720,20 +4635,20 @@ "type": "github" } ], - "time": "2021-03-17T06:17:11+00:00" + "time": "2020-10-26T13:14:26+00:00" }, { "name": "sebastian/recursion-context", - "version": "dev-master", + "version": "4.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "249976376508ed7e83b6dc429cd883a44b2a3c51" + "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/249976376508ed7e83b6dc429cd883a44b2a3c51", - "reference": "249976376508ed7e83b6dc429cd883a44b2a3c51", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/cd9d8cf3c5804de4341c283ed787f099f5506172", + "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172", "shasum": "" }, "require": { @@ -4742,7 +4657,6 @@ "require-dev": { "phpunit/phpunit": "^9.3" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -4776,7 +4690,7 @@ "homepage": "http://www.github.com/sebastianbergmann/recursion-context", "support": { "issues": "https://github.com/sebastianbergmann/recursion-context/issues", - "source": "https://github.com/sebastianbergmann/recursion-context/tree/master" + "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.4" }, "funding": [ { @@ -4784,11 +4698,11 @@ "type": "github" } ], - "time": "2021-03-17T06:17:43+00:00" + "time": "2020-10-26T13:17:30+00:00" }, { "name": "sebastian/resource-operations", - "version": "dev-master", + "version": "3.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/resource-operations.git", @@ -4806,7 +4720,6 @@ "require-dev": { "phpunit/phpunit": "^9.0" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -4844,16 +4757,16 @@ }, { "name": "sebastian/type", - "version": "dev-master", + "version": "2.3.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/type.git", - "reference": "e02c851008e26557b4f1b4ffd139b71c96937b04" + "reference": "81cd61ab7bbf2de744aba0ea61fae32f721df3d2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/e02c851008e26557b4f1b4ffd139b71c96937b04", - "reference": "e02c851008e26557b4f1b4ffd139b71c96937b04", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/81cd61ab7bbf2de744aba0ea61fae32f721df3d2", + "reference": "81cd61ab7bbf2de744aba0ea61fae32f721df3d2", "shasum": "" }, "require": { @@ -4862,7 +4775,6 @@ "require-dev": { "phpunit/phpunit": "^9.3" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -4889,7 +4801,7 @@ "homepage": "https://github.com/sebastianbergmann/type", "support": { "issues": "https://github.com/sebastianbergmann/type/issues", - "source": "https://github.com/sebastianbergmann/type/tree/master" + "source": "https://github.com/sebastianbergmann/type/tree/2.3.1" }, "funding": [ { @@ -4897,7 +4809,7 @@ "type": "github" } ], - "time": "2021-03-17T06:17:51+00:00" + "time": "2020-10-26T13:18:59+00:00" }, { "name": "sebastian/version", @@ -4954,16 +4866,16 @@ }, { "name": "swoole/ide-helper", - "version": "4.6.2", + "version": "4.6.4", "source": { "type": "git", "url": "https://github.com/swoole/ide-helper.git", - "reference": "62d923e3406d4d9c5a4749d810d11e2beb201abe" + "reference": "7e5c51ce7cc8c03ffb836aad31f3f27cd871aa96" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/swoole/ide-helper/zipball/62d923e3406d4d9c5a4749d810d11e2beb201abe", - "reference": "62d923e3406d4d9c5a4749d810d11e2beb201abe", + "url": "https://api.github.com/repos/swoole/ide-helper/zipball/7e5c51ce7cc8c03ffb836aad31f3f27cd871aa96", + "reference": "7e5c51ce7cc8c03ffb836aad31f3f27cd871aa96", "shasum": "" }, "require-dev": { @@ -4986,27 +4898,26 @@ "description": "IDE help files for Swoole.", "support": { "issues": "https://github.com/swoole/ide-helper/issues", - "source": "https://github.com/swoole/ide-helper/tree/4.6.2" + "source": "https://github.com/swoole/ide-helper/tree/4.6.4" }, - "time": "2021-01-26T00:17:29+00:00" + "time": "2021-03-11T19:44:34+00:00" }, { "name": "symfony/console", - "version": "5.x-dev", + "version": "v5.2.6", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "5da8b675121f9f4419b7052caa0cc6118a3ccd47" + "reference": "35f039df40a3b335ebf310f244cb242b3a83ac8d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/5da8b675121f9f4419b7052caa0cc6118a3ccd47", - "reference": "5da8b675121f9f4419b7052caa0cc6118a3ccd47", + "url": "https://api.github.com/repos/symfony/console/zipball/35f039df40a3b335ebf310f244cb242b3a83ac8d", + "reference": "35f039df40a3b335ebf310f244cb242b3a83ac8d", "shasum": "" }, "require": { "php": ">=7.2.5", - "symfony/deprecation-contracts": "^2.1", "symfony/polyfill-mbstring": "~1.0", "symfony/polyfill-php73": "^1.8", "symfony/polyfill-php80": "^1.15", @@ -5038,7 +4949,6 @@ "symfony/lock": "", "symfony/process": "" }, - "default-branch": true, "type": "library", "autoload": { "psr-4": { @@ -5071,7 +4981,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/5.x" + "source": "https://github.com/symfony/console/tree/v5.2.6" }, "funding": [ { @@ -5087,79 +4997,11 @@ "type": "tidelift" } ], - "time": "2021-03-23T14:20:07+00:00" - }, - { - "name": "symfony/deprecation-contracts", - "version": "dev-main", - "source": { - "type": "git", - "url": "https://github.com/symfony/deprecation-contracts.git", - "reference": "5f38c8804a9e97d23e0c8d63341088cd8a22d627" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/5f38c8804a9e97d23e0c8d63341088cd8a22d627", - "reference": "5f38c8804a9e97d23e0c8d63341088cd8a22d627", - "shasum": "" - }, - "require": { - "php": ">=7.1" - }, - "default-branch": true, - "type": "library", - "extra": { - "branch-alias": { - "dev-main": "2.4-dev" - }, - "thanks": { - "name": "symfony/contracts", - "url": "https://github.com/symfony/contracts" - } - }, - "autoload": { - "files": [ - "function.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "A generic function and convention to trigger deprecation notices", - "homepage": "https://symfony.com", - "support": { - "source": "https://github.com/symfony/deprecation-contracts/tree/main" - }, - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "time": "2021-03-23T23:28:01+00:00" + "time": "2021-03-28T09:42:18+00:00" }, { "name": "symfony/polyfill-intl-grapheme", - "version": "dev-main", + "version": "v1.22.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-grapheme.git", @@ -5177,7 +5019,6 @@ "suggest": { "ext-intl": "For best performance" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -5241,7 +5082,7 @@ }, { "name": "symfony/polyfill-intl-normalizer", - "version": "dev-main", + "version": "v1.22.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-normalizer.git", @@ -5259,7 +5100,6 @@ "suggest": { "ext-intl": "For best performance" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -5326,7 +5166,7 @@ }, { "name": "symfony/polyfill-mbstring", - "version": "dev-main", + "version": "v1.22.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", @@ -5344,7 +5184,6 @@ "suggest": { "ext-mbstring": "For best performance" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -5407,7 +5246,7 @@ }, { "name": "symfony/polyfill-php73", - "version": "dev-main", + "version": "v1.22.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php73.git", @@ -5422,7 +5261,6 @@ "require": { "php": ">=7.1" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -5487,7 +5325,7 @@ }, { "name": "symfony/polyfill-php80", - "version": "dev-main", + "version": "v1.22.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php80.git", @@ -5502,7 +5340,6 @@ "require": { "php": ">=7.1" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -5571,30 +5408,29 @@ }, { "name": "symfony/service-contracts", - "version": "dev-main", + "version": "v2.2.0", "source": { "type": "git", "url": "https://github.com/symfony/service-contracts.git", - "reference": "1309413986521646bb0ba91140afdc2a61ed8cfe" + "reference": "d15da7ba4957ffb8f1747218be9e1a121fd298a1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/service-contracts/zipball/1309413986521646bb0ba91140afdc2a61ed8cfe", - "reference": "1309413986521646bb0ba91140afdc2a61ed8cfe", + "url": "https://api.github.com/repos/symfony/service-contracts/zipball/d15da7ba4957ffb8f1747218be9e1a121fd298a1", + "reference": "d15da7ba4957ffb8f1747218be9e1a121fd298a1", "shasum": "" }, "require": { "php": ">=7.2.5", - "psr/container": "^1.1" + "psr/container": "^1.0" }, "suggest": { "symfony/service-implementation": "" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { - "dev-main": "2.4-dev" + "dev-master": "2.2-dev" }, "thanks": { "name": "symfony/contracts", @@ -5631,7 +5467,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/service-contracts/tree/main" + "source": "https://github.com/symfony/service-contracts/tree/master" }, "funding": [ { @@ -5647,20 +5483,20 @@ "type": "tidelift" } ], - "time": "2021-03-23T23:28:01+00:00" + "time": "2020-09-07T11:33:47+00:00" }, { "name": "symfony/string", - "version": "5.x-dev", + "version": "v5.2.6", "source": { "type": "git", "url": "https://github.com/symfony/string.git", - "reference": "01454c66c88a6bb4449dcdeb913e463e075f331b" + "reference": "ad0bd91bce2054103f5eaa18ebeba8d3bc2a0572" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/string/zipball/01454c66c88a6bb4449dcdeb913e463e075f331b", - "reference": "01454c66c88a6bb4449dcdeb913e463e075f331b", + "url": "https://api.github.com/repos/symfony/string/zipball/ad0bd91bce2054103f5eaa18ebeba8d3bc2a0572", + "reference": "ad0bd91bce2054103f5eaa18ebeba8d3bc2a0572", "shasum": "" }, "require": { @@ -5677,7 +5513,6 @@ "symfony/translation-contracts": "^1.1|^2", "symfony/var-exporter": "^4.4|^5.0" }, - "default-branch": true, "type": "library", "autoload": { "psr-4": { @@ -5715,7 +5550,7 @@ "utf8" ], "support": { - "source": "https://github.com/symfony/string/tree/5.x" + "source": "https://github.com/symfony/string/tree/v5.2.6" }, "funding": [ { @@ -5731,7 +5566,7 @@ "type": "tidelift" } ], - "time": "2021-03-17T17:12:23+00:00" + "time": "2021-03-17T17:12:15+00:00" }, { "name": "theseer/tokenizer", @@ -5785,16 +5620,16 @@ }, { "name": "twig/twig", - "version": "2.x-dev", + "version": "v2.14.4", "source": { "type": "git", "url": "https://github.com/twigphp/Twig.git", - "reference": "116bfb0bc9ec2a39db93431b7fe67144164d251e" + "reference": "0b4ba691fb99ec7952d25deb36c0a83061b93bbf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/twigphp/Twig/zipball/116bfb0bc9ec2a39db93431b7fe67144164d251e", - "reference": "116bfb0bc9ec2a39db93431b7fe67144164d251e", + "url": "https://api.github.com/repos/twigphp/Twig/zipball/0b4ba691fb99ec7952d25deb36c0a83061b93bbf", + "reference": "0b4ba691fb99ec7952d25deb36c0a83061b93bbf", "shasum": "" }, "require": { @@ -5848,7 +5683,7 @@ ], "support": { "issues": "https://github.com/twigphp/Twig/issues", - "source": "https://github.com/twigphp/Twig/tree/2.x" + "source": "https://github.com/twigphp/Twig/tree/v2.14.4" }, "funding": [ { @@ -5860,24 +5695,24 @@ "type": "tidelift" } ], - "time": "2021-03-22T08:23:49+00:00" + "time": "2021-03-10T10:05:55+00:00" }, { "name": "vimeo/psalm", - "version": "4.1.1", + "version": "4.7.0", "source": { "type": "git", "url": "https://github.com/vimeo/psalm.git", - "reference": "16bfbd9224698bd738c665f33039fade2a1a3977" + "reference": "d4377c0baf3ffbf0b1ec6998e8d1be2a40971005" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vimeo/psalm/zipball/16bfbd9224698bd738c665f33039fade2a1a3977", - "reference": "16bfbd9224698bd738c665f33039fade2a1a3977", + "url": "https://api.github.com/repos/vimeo/psalm/zipball/d4377c0baf3ffbf0b1ec6998e8d1be2a40971005", + "reference": "d4377c0baf3ffbf0b1ec6998e8d1be2a40971005", "shasum": "" }, "require": { - "amphp/amp": "^2.1", + "amphp/amp": "^2.4.2", "amphp/byte-stream": "^1.5", "composer/package-versions-deprecated": "^1.8.0", "composer/semver": "^1.4 || ^2.0 || ^3.0", @@ -5890,8 +5725,8 @@ "ext-simplexml": "*", "ext-tokenizer": "*", "felixfbecker/advanced-json-rpc": "^3.0.3", - "felixfbecker/language-server-protocol": "^1.4", - "netresearch/jsonmapper": "^1.0 || ^2.0 || ^3.0", + "felixfbecker/language-server-protocol": "^1.5", + "netresearch/jsonmapper": "^1.0 || ^2.0 || ^3.0 || ^4.0", "nikic/php-parser": "^4.10.1", "openlss/lib-array2xml": "^1.0", "php": "^7.1|^8", @@ -5903,19 +5738,19 @@ "psalm/psalm": "self.version" }, "require-dev": { - "amphp/amp": "^2.4.2", "bamarni/composer-bin-plugin": "^1.2", - "brianium/paratest": "^4.0.0", + "brianium/paratest": "^4.0||^6.0", "ext-curl": "*", - "php": "^7.3|^8", + "php-parallel-lint/php-parallel-lint": "^1.2", "phpdocumentor/reflection-docblock": "^5", - "phpmyadmin/sql-parser": "5.1.0", + "phpmyadmin/sql-parser": "5.1.0||dev-master", "phpspec/prophecy": ">=1.9.0", "phpunit/phpunit": "^9.0", "psalm/plugin-phpunit": "^0.13", - "slevomat/coding-standard": "^5.0", + "slevomat/coding-standard": "^6.3.11", "squizlabs/php_codesniffer": "^3.5", "symfony/process": "^4.3", + "weirdan/phpunit-appveyor-reporter": "^1.0.0", "weirdan/prophecy-shim": "^1.0 || ^2.0" }, "suggest": { @@ -5963,33 +5798,32 @@ ], "support": { "issues": "https://github.com/vimeo/psalm/issues", - "source": "https://github.com/vimeo/psalm/tree/4.1.1" + "source": "https://github.com/vimeo/psalm/tree/4.7.0" }, - "time": "2020-11-02T05:54:12+00:00" + "time": "2021-03-29T03:54:38+00:00" }, { "name": "webmozart/path-util", - "version": "dev-master", + "version": "2.3.0", "source": { "type": "git", "url": "https://github.com/webmozart/path-util.git", - "reference": "95a8f7ad150c2a3773ff3c3d04f557a24c99cfd2" + "reference": "d939f7edc24c9a1bb9c0dee5cb05d8e859490725" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/webmozart/path-util/zipball/95a8f7ad150c2a3773ff3c3d04f557a24c99cfd2", - "reference": "95a8f7ad150c2a3773ff3c3d04f557a24c99cfd2", + "url": "https://api.github.com/repos/webmozart/path-util/zipball/d939f7edc24c9a1bb9c0dee5cb05d8e859490725", + "reference": "d939f7edc24c9a1bb9c0dee5cb05d8e859490725", "shasum": "" }, "require": { - "php": "^5.3.3|^7.0", + "php": ">=5.3.3", "webmozart/assert": "~1.0" }, "require-dev": { "phpunit/phpunit": "^4.6", "sebastian/version": "^1.0.1" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -6014,13 +5848,13 @@ "description": "A robust cross-platform utility for normalizing, comparing and modifying file paths.", "support": { "issues": "https://github.com/webmozart/path-util/issues", - "source": "https://github.com/webmozart/path-util/tree/master" + "source": "https://github.com/webmozart/path-util/tree/2.3.0" }, - "time": "2016-08-15T15:31:42+00:00" + "time": "2015-12-17T08:42:14+00:00" } ], "aliases": [], - "minimum-stability": "dev", + "minimum-stability": "stable", "stability-flags": [], "prefer-stable": false, "prefer-lowest": false, @@ -6041,7 +5875,7 @@ }, "platform-dev": [], "platform-overrides": { - "php": "7.4" + "php": "8.0" }, "plugin-api-version": "2.0.0" } From 6b3ea91e66ddb3a511c39096b7c074336bede9b3 Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Fri, 9 Apr 2021 12:41:22 +0200 Subject: [PATCH 026/111] deps: update php extensions --- Dockerfile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 2658229b61..48cb86b062 100755 --- a/Dockerfile +++ b/Dockerfile @@ -14,9 +14,9 @@ RUN composer update --ignore-platform-reqs --optimize-autoloader \ FROM php:8.0-cli-alpine as step1 -ENV PHP_REDIS_VERSION=5.3.3 \ - PHP_SWOOLE_VERSION=v4.6.3 \ - PHP_IMAGICK_VERSION=master \ +ENV PHP_REDIS_VERSION=5.3.4 \ + PHP_SWOOLE_VERSION=v4.6.4 \ + PHP_IMAGICK_VERSION=3.4.4 \ PHP_YAML_VERSION=2.2.1 \ PHP_MAXMINDDB_VERSION=v1.10.0 From 6dd2cc1af204e2fc067d5d5659ecff2ecc249fd6 Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Fri, 9 Apr 2021 12:54:50 +0200 Subject: [PATCH 027/111] deps: set imagich to master version until php8 is officialy released --- Dockerfile | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) diff --git a/Dockerfile b/Dockerfile index 48cb86b062..d8fb647252 100755 --- a/Dockerfile +++ b/Dockerfile @@ -16,7 +16,7 @@ FROM php:8.0-cli-alpine as step1 ENV PHP_REDIS_VERSION=5.3.4 \ PHP_SWOOLE_VERSION=v4.6.4 \ - PHP_IMAGICK_VERSION=3.4.4 \ + PHP_IMAGICK_VERSION=master \ PHP_YAML_VERSION=2.2.1 \ PHP_MAXMINDDB_VERSION=v1.10.0 @@ -39,41 +39,36 @@ RUN docker-php-ext-install sockets RUN \ # Redis Extension - git clone https://github.com/phpredis/phpredis.git && \ + git clone --depth 1 --branch $PHP_REDIS_VERSION https://github.com/phpredis/phpredis.git && \ cd phpredis && \ - git checkout $PHP_REDIS_VERSION && \ phpize && \ ./configure && \ make && make install && \ cd .. && \ ## Swoole Extension - git clone https://github.com/swoole/swoole-src.git && \ + git clone --depth 1 --branch $PHP_SWOOLE_VERSION https://github.com/swoole/swoole-src.git && \ cd swoole-src && \ - git checkout $PHP_SWOOLE_VERSION && \ phpize && \ ./configure --enable-http2 && \ make && make install && \ cd .. && \ ## Imagick Extension - git clone https://github.com/Imagick/imagick && \ + git clone --depth 1 --branch $PHP_IMAGICK_VERSION -https://github.com/Imagick/imagick && \ cd imagick && \ - git checkout $PHP_IMAGICK_VERSION && \ phpize && \ ./configure && \ make && make install && \ cd .. && \ ## YAML Extension - git clone https://github.com/php/pecl-file_formats-yaml && \ + git clone --depth 1 --branch $PHP_YAML_VERSION https://github.com/php/pecl-file_formats-yaml && \ cd pecl-file_formats-yaml && \ - git checkout $PHP_YAML_VERSION && \ phpize && \ ./configure && \ make && make install && \ cd .. && \ ## Maxminddb extension - git clone https://github.com/maxmind/MaxMind-DB-Reader-php.git && \ + git clone --depth 1 --branch $PHP_MAXMINDDB_VERSION https://github.com/maxmind/MaxMind-DB-Reader-php.git && \ cd MaxMind-DB-Reader-php && \ - git checkout $PHP_MAXMINDDB_VERSION && \ cd ext && \ phpize && \ ./configure && \ From 65c3e2536e8779759a8aa53511df396ff64804aa Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Fri, 9 Apr 2021 13:02:11 +0200 Subject: [PATCH 028/111] deps: fix missplaced dash --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index d8fb647252..ffa85b4b47 100755 --- a/Dockerfile +++ b/Dockerfile @@ -53,7 +53,7 @@ RUN \ make && make install && \ cd .. && \ ## Imagick Extension - git clone --depth 1 --branch $PHP_IMAGICK_VERSION -https://github.com/Imagick/imagick && \ + git clone --depth 1 --branch $PHP_IMAGICK_VERSION https://github.com/Imagick/imagick && \ cd imagick && \ phpize && \ ./configure && \ From e021b8795af734601bc06ec42560daa628597e7c Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Wed, 14 Apr 2021 12:40:55 +0200 Subject: [PATCH 029/111] fix: enable coroutine in functions worker --- app/workers/functions.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/workers/functions.php b/app/workers/functions.php index 78c728f329..8f6afb6e2f 100644 --- a/app/workers/functions.php +++ b/app/workers/functions.php @@ -25,6 +25,8 @@ $environments = Config::getParam('environments'); */ $warmupStart = \microtime(true); +Runtime::setHookFlags(SWOOLE_HOOK_ALL); + Co\run(function() use ($environments) { // Warmup: make sure images are ready to run fast 🚀 Runtime::enableCoroutine(SWOOLE_HOOK_ALL); From d97e1674aacc8ea4423e798e833b21c06e953555 Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Wed, 14 Apr 2021 15:07:26 +0200 Subject: [PATCH 030/111] tests: fix --- app/workers/functions.php | 7 +++---- tests/e2e/Services/Account/AccountCustomClientTest.php | 2 +- tests/unit/General/CollectionsTest.php | 2 +- 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/app/workers/functions.php b/app/workers/functions.php index 8f6afb6e2f..ed960d202e 100644 --- a/app/workers/functions.php +++ b/app/workers/functions.php @@ -14,8 +14,10 @@ use Utopia\Config\Config; require_once __DIR__.'/../init.php'; -Console::title('Functions V1 Worker'); +Runtime::setHookFlags(SWOOLE_HOOK_ALL); +Runtime::enableCoroutine(SWOOLE_HOOK_ALL); +Console::title('Functions V1 Worker'); Console::success(APP_NAME.' functions worker v1 has started'); $environments = Config::getParam('environments'); @@ -25,10 +27,7 @@ $environments = Config::getParam('environments'); */ $warmupStart = \microtime(true); -Runtime::setHookFlags(SWOOLE_HOOK_ALL); - Co\run(function() use ($environments) { // Warmup: make sure images are ready to run fast 🚀 - Runtime::enableCoroutine(SWOOLE_HOOK_ALL); $dockerUser = App::getEnv('DOCKERHUB_PULL_USERNAME', null); $dockerPass = App::getEnv('DOCKERHUB_PULL_PASSWORD', null); diff --git a/tests/e2e/Services/Account/AccountCustomClientTest.php b/tests/e2e/Services/Account/AccountCustomClientTest.php index e1dedd6be9..b247347dd6 100644 --- a/tests/e2e/Services/Account/AccountCustomClientTest.php +++ b/tests/e2e/Services/Account/AccountCustomClientTest.php @@ -301,7 +301,7 @@ class AccountCustomClientTest extends Scope 'password' => '', ]); - $this->assertEquals($response['headers']['status-code'], 401); + $this->assertEquals(401, $response['headers']['status-code']); return []; } diff --git a/tests/unit/General/CollectionsTest.php b/tests/unit/General/CollectionsTest.php index bf7aea7c0c..8f84b35a12 100644 --- a/tests/unit/General/CollectionsTest.php +++ b/tests/unit/General/CollectionsTest.php @@ -20,7 +20,7 @@ class CollectionsTest extends TestCase public function testDuplicateRules() { foreach ($this->collections as $collection) { - if ($collection['rules']) { + if (in_array('rules', $collection)) { foreach ($collection['rules'] as $check) { $occurences = 0; foreach ($collection['rules'] as $rule) { From 942bd4d56f0af57af22e58df7c10039452247462 Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Wed, 14 Apr 2021 16:39:04 +0200 Subject: [PATCH 031/111] fix: collection unit test --- tests/unit/General/CollectionsTest.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/unit/General/CollectionsTest.php b/tests/unit/General/CollectionsTest.php index 8f84b35a12..b5d29bd24b 100644 --- a/tests/unit/General/CollectionsTest.php +++ b/tests/unit/General/CollectionsTest.php @@ -19,8 +19,8 @@ class CollectionsTest extends TestCase public function testDuplicateRules() { - foreach ($this->collections as $collection) { - if (in_array('rules', $collection)) { + foreach ($this->collections as $key => $collection) { + if (array_key_exists('rules', $collection)) { foreach ($collection['rules'] as $check) { $occurences = 0; foreach ($collection['rules'] as $rule) { From 32587f9d80b7f404a0f8d5fa01fbaaac0d5ed05a Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Wed, 14 Apr 2021 17:09:36 +0200 Subject: [PATCH 032/111] tests: disable test --- .travis.yml | 6 +++--- app/workers/functions.php | 3 +-- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/.travis.yml b/.travis.yml index b82fc05c1d..08032f8c1b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -36,9 +36,9 @@ script: - docker ps - docker-compose logs appwrite - docker-compose logs appwrite-worker-functions -- docker-compose exec appwrite doctor -- docker-compose exec appwrite vars -- docker-compose exec appwrite test --debug +# - docker-compose exec appwrite doctor +# - docker-compose exec appwrite vars +# - docker-compose exec appwrite test --debug deploy: - provider: script diff --git a/app/workers/functions.php b/app/workers/functions.php index ed960d202e..fdf788f342 100644 --- a/app/workers/functions.php +++ b/app/workers/functions.php @@ -14,8 +14,7 @@ use Utopia\Config\Config; require_once __DIR__.'/../init.php'; -Runtime::setHookFlags(SWOOLE_HOOK_ALL); -Runtime::enableCoroutine(SWOOLE_HOOK_ALL); +Runtime::enableCoroutine(true, SWOOLE_HOOK_ALL); Console::title('Functions V1 Worker'); Console::success(APP_NAME.' functions worker v1 has started'); From 8f7c679604100d12bacbe721ae1cb6017804c44b Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Wed, 14 Apr 2021 17:25:30 +0200 Subject: [PATCH 033/111] tests: enable tests again --- .travis.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index 08032f8c1b..b82fc05c1d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -36,9 +36,9 @@ script: - docker ps - docker-compose logs appwrite - docker-compose logs appwrite-worker-functions -# - docker-compose exec appwrite doctor -# - docker-compose exec appwrite vars -# - docker-compose exec appwrite test --debug +- docker-compose exec appwrite doctor +- docker-compose exec appwrite vars +- docker-compose exec appwrite test --debug deploy: - provider: script From 74908f4965ac8f10980751ef5c27110cb8f12e68 Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Wed, 14 Apr 2021 17:55:08 +0200 Subject: [PATCH 034/111] fix: disable co-routine hooks --- app/workers/functions.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/workers/functions.php b/app/workers/functions.php index fdf788f342..1e7ed90936 100644 --- a/app/workers/functions.php +++ b/app/workers/functions.php @@ -14,7 +14,7 @@ use Utopia\Config\Config; require_once __DIR__.'/../init.php'; -Runtime::enableCoroutine(true, SWOOLE_HOOK_ALL); +Runtime::enableCoroutine(FALSE); Console::title('Functions V1 Worker'); Console::success(APP_NAME.' functions worker v1 has started'); From b7833a862b13cf66ce4286f58254b0fb73987a3f Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Wed, 14 Apr 2021 17:56:15 +0200 Subject: [PATCH 035/111] fix: disable co-routine hooks --- app/workers/functions.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/workers/functions.php b/app/workers/functions.php index 1e7ed90936..f04062f5f3 100644 --- a/app/workers/functions.php +++ b/app/workers/functions.php @@ -14,7 +14,7 @@ use Utopia\Config\Config; require_once __DIR__.'/../init.php'; -Runtime::enableCoroutine(FALSE); +Runtime::enableCoroutine(SWOOLE_HOOK_ALL); Console::title('Functions V1 Worker'); Console::success(APP_NAME.' functions worker v1 has started'); @@ -64,6 +64,8 @@ $warmupTime = $warmupEnd - $warmupStart; Console::success('Finished warmup in '.$warmupTime.' seconds'); +Runtime::setHookFlags(0); + /** * List function servers */ From 2f7f8ab03d65f19eaa30188ab135acf3ca55f551 Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Fri, 16 Apr 2021 17:53:36 +0200 Subject: [PATCH 036/111] test: disabling coroutine in functions worker --- app/workers/functions.php | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/app/workers/functions.php b/app/workers/functions.php index f04062f5f3..71c30e9f1c 100644 --- a/app/workers/functions.php +++ b/app/workers/functions.php @@ -14,7 +14,7 @@ use Utopia\Config\Config; require_once __DIR__.'/../init.php'; -Runtime::enableCoroutine(SWOOLE_HOOK_ALL); +// Runtime::enableCoroutine(SWOOLE_HOOK_ALL); Console::title('Functions V1 Worker'); Console::success(APP_NAME.' functions worker v1 has started'); @@ -26,7 +26,7 @@ $environments = Config::getParam('environments'); */ $warmupStart = \microtime(true); -Co\run(function() use ($environments) { // Warmup: make sure images are ready to run fast 🚀 +// Co\run(function() use ($environments) { // Warmup: make sure images are ready to run fast 🚀 $dockerUser = App::getEnv('DOCKERHUB_PULL_USERNAME', null); $dockerPass = App::getEnv('DOCKERHUB_PULL_PASSWORD', null); @@ -40,7 +40,7 @@ Co\run(function() use ($environments) { // Warmup: make sure images are ready t } foreach($environments as $environment) { - go(function() use ($environment) { + // go(function() use ($environment) { $stdout = ''; $stderr = ''; @@ -55,17 +55,15 @@ Co\run(function() use ($environments) { // Warmup: make sure images are ready t if(!empty($stderr)) { Console::error($stderr); } - }); + // }); } -}); +// }); $warmupEnd = \microtime(true); $warmupTime = $warmupEnd - $warmupStart; Console::success('Finished warmup in '.$warmupTime.' seconds'); -Runtime::setHookFlags(0); - /** * List function servers */ From 3b989cf6a73ce0fc2a582eb03b11d6c2bd8a95bc Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Fri, 16 Apr 2021 18:50:16 +0200 Subject: [PATCH 037/111] fix: anonymous account tests --- app/workers/functions.php | 10 +++++----- .../e2e/Services/Account/AccountCustomClientTest.php | 12 ++++++------ 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/app/workers/functions.php b/app/workers/functions.php index 71c30e9f1c..19851dfa82 100644 --- a/app/workers/functions.php +++ b/app/workers/functions.php @@ -14,7 +14,7 @@ use Utopia\Config\Config; require_once __DIR__.'/../init.php'; -// Runtime::enableCoroutine(SWOOLE_HOOK_ALL); +Runtime::enableCoroutine(0); Console::title('Functions V1 Worker'); Console::success(APP_NAME.' functions worker v1 has started'); @@ -26,7 +26,7 @@ $environments = Config::getParam('environments'); */ $warmupStart = \microtime(true); -// Co\run(function() use ($environments) { // Warmup: make sure images are ready to run fast 🚀 +Co\run(function() use ($environments) { // Warmup: make sure images are ready to run fast 🚀 $dockerUser = App::getEnv('DOCKERHUB_PULL_USERNAME', null); $dockerPass = App::getEnv('DOCKERHUB_PULL_PASSWORD', null); @@ -40,7 +40,7 @@ $warmupStart = \microtime(true); } foreach($environments as $environment) { - // go(function() use ($environment) { + go(function() use ($environment) { $stdout = ''; $stderr = ''; @@ -55,9 +55,9 @@ $warmupStart = \microtime(true); if(!empty($stderr)) { Console::error($stderr); } - // }); + }); } -// }); +}); $warmupEnd = \microtime(true); $warmupTime = $warmupEnd - $warmupStart; diff --git a/tests/e2e/Services/Account/AccountCustomClientTest.php b/tests/e2e/Services/Account/AccountCustomClientTest.php index b247347dd6..bc274996f9 100644 --- a/tests/e2e/Services/Account/AccountCustomClientTest.php +++ b/tests/e2e/Services/Account/AccountCustomClientTest.php @@ -261,7 +261,7 @@ class AccountCustomClientTest extends Scope /** * @depends testCreateAnonymousAccount */ - public function testUpdateAnonymousAccountPassword($session):array + public function testUpdateAnonymousAccountPassword($session) { /** * Test for FAILURE @@ -278,13 +278,13 @@ class AccountCustomClientTest extends Scope $this->assertEquals($response['headers']['status-code'], 400); - return []; + return $session; } /** * @depends testUpdateAnonymousAccountPassword */ - public function testUpdateAnonymousAccountEmail($session):array + public function testUpdateAnonymousAccountEmail($session) { $email = uniqid().'new@localhost.test'; @@ -301,12 +301,12 @@ class AccountCustomClientTest extends Scope 'password' => '', ]); - $this->assertEquals(401, $response['headers']['status-code']); + $this->assertEquals(400, $response['headers']['status-code']); return []; } - public function testConvertAnonymousAccount():array + public function testConvertAnonymousAccount() { $session = $this->testCreateAnonymousAccount(); $email = uniqid().'new@localhost.test'; @@ -372,7 +372,7 @@ class AccountCustomClientTest extends Scope return []; } - public function testConvertAnonymousAccountOAuth2():array + public function testConvertAnonymousAccountOAuth2() { $session = $this->testCreateAnonymousAccount(); $provider = 'mock'; From ca8920a152b4ea5b854efb11c29c875f8aa9776f Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Fri, 16 Apr 2021 19:07:25 +0200 Subject: [PATCH 038/111] style: fix typo --- tests/e2e/Services/Locale/LocaleBase.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/e2e/Services/Locale/LocaleBase.php b/tests/e2e/Services/Locale/LocaleBase.php index 0ad3ed076b..ac492a69b7 100644 --- a/tests/e2e/Services/Locale/LocaleBase.php +++ b/tests/e2e/Services/Locale/LocaleBase.php @@ -222,7 +222,7 @@ trait LocaleBase return []; } - public function testLangaugaes(): array + public function testLanguagaes(): array { /** * Test for SUCCESS From bd02df15af4c1403f1f93a20d6642e9de0078500 Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Fri, 16 Apr 2021 19:10:12 +0200 Subject: [PATCH 039/111] deps: update composer after merge --- composer.lock | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/composer.lock b/composer.lock index 81c9be47a1..2973a6fd46 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "db8c792c684aa44ba5b9808bc7822c21", + "content-hash": "cfefdafe4479ebdb11009e325af10418", "packages": [ { "name": "adhocore/jwt", @@ -1687,16 +1687,16 @@ }, { "name": "utopia-php/image", - "version": "0.2.0", + "version": "0.2.1", "source": { "type": "git", "url": "https://github.com/utopia-php/image.git", - "reference": "3b22910b0257657ba40e853918cb7c9d19fba125" + "reference": "0754955a165483852184d1215cc3bf659432d23a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/image/zipball/3b22910b0257657ba40e853918cb7c9d19fba125", - "reference": "3b22910b0257657ba40e853918cb7c9d19fba125", + "url": "https://api.github.com/repos/utopia-php/image/zipball/0754955a165483852184d1215cc3bf659432d23a", + "reference": "0754955a165483852184d1215cc3bf659432d23a", "shasum": "" }, "require": { @@ -1734,9 +1734,9 @@ ], "support": { "issues": "https://github.com/utopia-php/image/issues", - "source": "https://github.com/utopia-php/image/tree/0.2.0" + "source": "https://github.com/utopia-php/image/tree/0.2.1" }, - "time": "2021-03-18T04:49:59+00:00" + "time": "2021-04-13T07:47:24+00:00" }, { "name": "utopia-php/locale", @@ -5855,7 +5855,9 @@ ], "aliases": [], "minimum-stability": "stable", - "stability-flags": [], + "stability-flags": { + "appwrite/sdk-generator": 20 + }, "prefer-stable": false, "prefer-lowest": false, "platform": { From 474f45c85e2f3faefc4d4d1b8fff624626fbce7f Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Tue, 20 Apr 2021 10:37:27 +0200 Subject: [PATCH 040/111] tests: add timeout after executing fiunction for webhooks --- tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php b/tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php index c8e3ba747d..2ac18bac2d 100644 --- a/tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php +++ b/tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php @@ -461,6 +461,8 @@ class WebhooksCustomServerTest extends Scope $this->assertEquals($execution['headers']['status-code'], 201); $this->assertNotEmpty($execution['body']['$id']); + sleep(7); + $webhook = $this->getLastRequest(); $this->assertEquals($webhook['method'], 'POST'); @@ -471,8 +473,7 @@ class WebhooksCustomServerTest extends Scope $this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Id'] ?? '', $this->getProject()['webhookId']); $this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Project-Id'] ?? '', $this->getProject()['$id']); - // wait for timeout function to complete (sleep(5);) - sleep(6); + sleep(7); $webhook = $this->getLastRequest(); From fe819ee326681bc058ed51628095c98c9364fc8a Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Tue, 20 Apr 2021 12:01:40 +0200 Subject: [PATCH 041/111] tests: adjust schedule for functions --- .../Functions/FunctionsCustomClientTest.php | 4 +-- .../Functions/FunctionsCustomServerTest.php | 25 +++++++++++++++---- .../Webhooks/WebhooksCustomServerTest.php | 2 -- 3 files changed, 22 insertions(+), 9 deletions(-) diff --git a/tests/e2e/Services/Functions/FunctionsCustomClientTest.php b/tests/e2e/Services/Functions/FunctionsCustomClientTest.php index b4c604c5cc..fd6866f49f 100644 --- a/tests/e2e/Services/Functions/FunctionsCustomClientTest.php +++ b/tests/e2e/Services/Functions/FunctionsCustomClientTest.php @@ -33,7 +33,7 @@ class FunctionsCustomClientTest extends Scope 'account.create', 'account.delete', ], - 'schedule' => '* * * * *', + 'schedule' => '0 0 1 1 *', 'timeout' => 10, ]); @@ -64,7 +64,7 @@ class FunctionsCustomClientTest extends Scope 'account.create', 'account.delete', ], - 'schedule' => '* * * * *', + 'schedule' => '0 0 1 1 *', 'timeout' => 10, ]); diff --git a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php index 1184ba7730..e9bb6e6989 100644 --- a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php +++ b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php @@ -35,7 +35,7 @@ class FunctionsCustomServerTest extends Scope 'account.create', 'account.delete', ], - 'schedule' => '* * * * *', + 'schedule' => '0 0 1 1 *', 'timeout' => 10, ]); @@ -57,7 +57,7 @@ class FunctionsCustomServerTest extends Scope 'account.create', 'account.delete', ], $response1['body']['events']); - $this->assertEquals('* * * * *', $response1['body']['schedule']); + $this->assertEquals('0 0 1 1 *', $response1['body']['schedule']); $this->assertEquals(10, $response1['body']['timeout']); /** @@ -142,7 +142,7 @@ class FunctionsCustomServerTest extends Scope 'account.update.name', 'account.update.email', ], - 'schedule' => '* * * * 1', + 'schedule' => '0 0 1 2 *', 'timeout' => 5, ]); @@ -161,7 +161,7 @@ class FunctionsCustomServerTest extends Scope 'account.update.name', 'account.update.email', ], $response1['body']['events']); - $this->assertEquals('* * * * 1', $response1['body']['schedule']); + $this->assertEquals('0 0 1 2 *', $response1['body']['schedule']); $this->assertEquals(5, $response1['body']['timeout']); /** @@ -549,7 +549,7 @@ class FunctionsCustomServerTest extends Scope $envs[$key] = array_merge($env, $functions[$key]); } - sleep(count($envs) * 20); + //sleep(count($envs) * 20); fwrite(STDERR, "."); /** @@ -823,4 +823,19 @@ class FunctionsCustomServerTest extends Scope $this->assertEquals($executions['body']['executions'][0]['trigger'], 'http'); $this->assertStringContainsString('foobar', $executions['body']['executions'][0]['stdout']); } + + public function testCleanUp(): void + { + $functions = $this->client->call(Client::METHOD_GET, '/functions', array_merge([ + 'content-type' => 'application/json', + 'x-appwrite-project' => $this->getProject()['$id'], + ], $this->getHeaders())); + + foreach ($functions['body']['functions'] as $function) { + $this->client->call(Client::METHOD_DELETE, '/functions/'.$function['$id'], array_merge([ + 'content-type' => 'application/json', + 'x-appwrite-project' => $this->getProject()['$id'], + ], $this->getHeaders())); + } + } } diff --git a/tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php b/tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php index 2ac18bac2d..b08643e499 100644 --- a/tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php +++ b/tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php @@ -461,8 +461,6 @@ class WebhooksCustomServerTest extends Scope $this->assertEquals($execution['headers']['status-code'], 201); $this->assertNotEmpty($execution['body']['$id']); - sleep(7); - $webhook = $this->getLastRequest(); $this->assertEquals($webhook['method'], 'POST'); From 04fbb9b02b384934b1567012c6c2aaa293eb7aa0 Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Tue, 20 Apr 2021 12:27:41 +0200 Subject: [PATCH 042/111] tests: temporarily disable tests --- .../Functions/FunctionsCustomServerTest.php | 140 +++++++++--------- 1 file changed, 70 insertions(+), 70 deletions(-) diff --git a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php index e9bb6e6989..9f994eebbd 100644 --- a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php +++ b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php @@ -463,16 +463,16 @@ class FunctionsCustomServerTest extends Scope * bash tests/resources/functions/package-*.sh */ $functions = [ - 'node-14.5' => [ - 'code' => $functionsDir.'/node.tar.gz', - 'command' => 'node index.js', - 'timeout' => 15, - ], - 'node-15.5' => [ - 'code' => $functionsDir.'/node.tar.gz', - 'command' => 'node index.js', - 'timeout' => 15, - ], + // 'node-14.5' => [ + // 'code' => $functionsDir.'/node.tar.gz', + // 'command' => 'node index.js', + // 'timeout' => 15, + // ], + // 'node-15.5' => [ + // 'code' => $functionsDir.'/node.tar.gz', + // 'command' => 'node index.js', + // 'timeout' => 15, + // ], 'php-7.4' => [ 'code' => $functionsDir.'/php.tar.gz', 'command' => 'php index.php', @@ -483,66 +483,66 @@ class FunctionsCustomServerTest extends Scope 'command' => 'php index.php', 'timeout' => 15, ], - 'ruby-2.7' => [ - 'code' => $functionsDir.'/ruby.tar.gz', - 'command' => 'ruby app.rb', - 'timeout' => 15, - ], - 'ruby-3.0' => [ - 'code' => $functionsDir.'/ruby.tar.gz', - 'command' => 'ruby app.rb', - 'timeout' => 15, - ], - 'python-3.8' => [ - 'code' => $functionsDir.'/python.tar.gz', - 'command' => 'python main.py', - 'timeout' => 15, - ], - 'python-3.9' => [ - 'code' => $functionsDir.'/python.tar.gz', - 'command' => 'python main.py', - 'timeout' => 15, - ], - 'deno-1.2' => [ - 'code' => $functionsDir.'/deno.tar.gz', - 'command' => 'deno run --allow-env index.ts', - 'timeout' => 15, - ], - 'deno-1.5' => [ - 'code' => $functionsDir.'/deno.tar.gz', - 'command' => 'deno run --allow-env index.ts', - 'timeout' => 15, - ], - 'deno-1.6' => [ - 'code' => $functionsDir.'/deno.tar.gz', - 'command' => 'deno run --allow-env index.ts', - 'timeout' => 15, - ], - 'deno-1.8' => [ - 'code' => $functionsDir.'/deno.tar.gz', - 'command' => 'deno run --allow-env index.ts', - 'timeout' => 15, - ], - 'dart-2.10' => [ - 'code' => $functionsDir.'/dart.tar.gz', - 'command' => 'dart main.dart', - 'timeout' => 15, - ], - 'dart-2.12' => [ - 'code' => $functionsDir.'/dart.tar.gz', - 'command' => 'dart main.dart', - 'timeout' => 15, - ], - 'dotnet-3.1' => [ - 'code' => $functionsDir.'/dotnet-3.1.tar.gz', - 'command' => 'dotnet dotnet.dll', - 'timeout' => 15, - ], - 'dotnet-5.0' => [ - 'code' => $functionsDir.'/dotnet-5.0.tar.gz', - 'command' => 'dotnet dotnet.dll', - 'timeout' => 15, - ] + // 'ruby-2.7' => [ + // 'code' => $functionsDir.'/ruby.tar.gz', + // 'command' => 'ruby app.rb', + // 'timeout' => 15, + // ], + // 'ruby-3.0' => [ + // 'code' => $functionsDir.'/ruby.tar.gz', + // 'command' => 'ruby app.rb', + // 'timeout' => 15, + // ], + // 'python-3.8' => [ + // 'code' => $functionsDir.'/python.tar.gz', + // 'command' => 'python main.py', + // 'timeout' => 15, + // ], + // 'python-3.9' => [ + // 'code' => $functionsDir.'/python.tar.gz', + // 'command' => 'python main.py', + // 'timeout' => 15, + // ], + // 'deno-1.2' => [ + // 'code' => $functionsDir.'/deno.tar.gz', + // 'command' => 'deno run --allow-env index.ts', + // 'timeout' => 15, + // ], + // 'deno-1.5' => [ + // 'code' => $functionsDir.'/deno.tar.gz', + // 'command' => 'deno run --allow-env index.ts', + // 'timeout' => 15, + // ], + // 'deno-1.6' => [ + // 'code' => $functionsDir.'/deno.tar.gz', + // 'command' => 'deno run --allow-env index.ts', + // 'timeout' => 15, + // ], + // 'deno-1.8' => [ + // 'code' => $functionsDir.'/deno.tar.gz', + // 'command' => 'deno run --allow-env index.ts', + // 'timeout' => 15, + // ], + // 'dart-2.10' => [ + // 'code' => $functionsDir.'/dart.tar.gz', + // 'command' => 'dart main.dart', + // 'timeout' => 15, + // ], + // 'dart-2.12' => [ + // 'code' => $functionsDir.'/dart.tar.gz', + // 'command' => 'dart main.dart', + // 'timeout' => 15, + // ], + // 'dotnet-3.1' => [ + // 'code' => $functionsDir.'/dotnet-3.1.tar.gz', + // 'command' => 'dotnet dotnet.dll', + // 'timeout' => 15, + // ], + // 'dotnet-5.0' => [ + // 'code' => $functionsDir.'/dotnet-5.0.tar.gz', + // 'command' => 'dotnet dotnet.dll', + // 'timeout' => 15, + // ] ]; foreach ($envs as $key => $env) { From f6c163d4a51113d2de75f7f7a2f90bbe8aca386c Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Tue, 20 Apr 2021 12:28:23 +0200 Subject: [PATCH 043/111] Revert "tests: adjust schedule for functions" This reverts commit fe819ee326681bc058ed51628095c98c9364fc8a. --- .../Functions/FunctionsCustomClientTest.php | 4 +-- .../Functions/FunctionsCustomServerTest.php | 25 ++++--------------- .../Webhooks/WebhooksCustomServerTest.php | 2 ++ 3 files changed, 9 insertions(+), 22 deletions(-) diff --git a/tests/e2e/Services/Functions/FunctionsCustomClientTest.php b/tests/e2e/Services/Functions/FunctionsCustomClientTest.php index fd6866f49f..b4c604c5cc 100644 --- a/tests/e2e/Services/Functions/FunctionsCustomClientTest.php +++ b/tests/e2e/Services/Functions/FunctionsCustomClientTest.php @@ -33,7 +33,7 @@ class FunctionsCustomClientTest extends Scope 'account.create', 'account.delete', ], - 'schedule' => '0 0 1 1 *', + 'schedule' => '* * * * *', 'timeout' => 10, ]); @@ -64,7 +64,7 @@ class FunctionsCustomClientTest extends Scope 'account.create', 'account.delete', ], - 'schedule' => '0 0 1 1 *', + 'schedule' => '* * * * *', 'timeout' => 10, ]); diff --git a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php index 9f994eebbd..9398b0fab0 100644 --- a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php +++ b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php @@ -35,7 +35,7 @@ class FunctionsCustomServerTest extends Scope 'account.create', 'account.delete', ], - 'schedule' => '0 0 1 1 *', + 'schedule' => '* * * * *', 'timeout' => 10, ]); @@ -57,7 +57,7 @@ class FunctionsCustomServerTest extends Scope 'account.create', 'account.delete', ], $response1['body']['events']); - $this->assertEquals('0 0 1 1 *', $response1['body']['schedule']); + $this->assertEquals('* * * * *', $response1['body']['schedule']); $this->assertEquals(10, $response1['body']['timeout']); /** @@ -142,7 +142,7 @@ class FunctionsCustomServerTest extends Scope 'account.update.name', 'account.update.email', ], - 'schedule' => '0 0 1 2 *', + 'schedule' => '* * * * 1', 'timeout' => 5, ]); @@ -161,7 +161,7 @@ class FunctionsCustomServerTest extends Scope 'account.update.name', 'account.update.email', ], $response1['body']['events']); - $this->assertEquals('0 0 1 2 *', $response1['body']['schedule']); + $this->assertEquals('* * * * 1', $response1['body']['schedule']); $this->assertEquals(5, $response1['body']['timeout']); /** @@ -549,7 +549,7 @@ class FunctionsCustomServerTest extends Scope $envs[$key] = array_merge($env, $functions[$key]); } - //sleep(count($envs) * 20); + sleep(count($envs) * 20); fwrite(STDERR, "."); /** @@ -823,19 +823,4 @@ class FunctionsCustomServerTest extends Scope $this->assertEquals($executions['body']['executions'][0]['trigger'], 'http'); $this->assertStringContainsString('foobar', $executions['body']['executions'][0]['stdout']); } - - public function testCleanUp(): void - { - $functions = $this->client->call(Client::METHOD_GET, '/functions', array_merge([ - 'content-type' => 'application/json', - 'x-appwrite-project' => $this->getProject()['$id'], - ], $this->getHeaders())); - - foreach ($functions['body']['functions'] as $function) { - $this->client->call(Client::METHOD_DELETE, '/functions/'.$function['$id'], array_merge([ - 'content-type' => 'application/json', - 'x-appwrite-project' => $this->getProject()['$id'], - ], $this->getHeaders())); - } - } } diff --git a/tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php b/tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php index b08643e499..2ac18bac2d 100644 --- a/tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php +++ b/tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php @@ -461,6 +461,8 @@ class WebhooksCustomServerTest extends Scope $this->assertEquals($execution['headers']['status-code'], 201); $this->assertNotEmpty($execution['body']['$id']); + sleep(7); + $webhook = $this->getLastRequest(); $this->assertEquals($webhook['method'], 'POST'); From 26d8ef4e2355e3abf2d4994830ad5d9e2579fa1f Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Tue, 20 Apr 2021 12:28:30 +0200 Subject: [PATCH 044/111] Revert "tests: add timeout after executing fiunction for webhooks" This reverts commit 474f45c85e2f3faefc4d4d1b8fff624626fbce7f. --- tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php b/tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php index 2ac18bac2d..c8e3ba747d 100644 --- a/tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php +++ b/tests/e2e/Services/Webhooks/WebhooksCustomServerTest.php @@ -461,8 +461,6 @@ class WebhooksCustomServerTest extends Scope $this->assertEquals($execution['headers']['status-code'], 201); $this->assertNotEmpty($execution['body']['$id']); - sleep(7); - $webhook = $this->getLastRequest(); $this->assertEquals($webhook['method'], 'POST'); @@ -473,7 +471,8 @@ class WebhooksCustomServerTest extends Scope $this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Id'] ?? '', $this->getProject()['webhookId']); $this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Project-Id'] ?? '', $this->getProject()['$id']); - sleep(7); + // wait for timeout function to complete (sleep(5);) + sleep(6); $webhook = $this->getLastRequest(); From 6ed97886f91a21749111c9a5a0adf3a36c6b634f Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Tue, 20 Apr 2021 12:51:29 +0200 Subject: [PATCH 045/111] tests: fix env skip for functions --- tests/e2e/Services/Functions/FunctionsCustomServerTest.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php index 9398b0fab0..85fa3c9bf6 100644 --- a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php +++ b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php @@ -546,7 +546,11 @@ class FunctionsCustomServerTest extends Scope ]; foreach ($envs as $key => $env) { - $envs[$key] = array_merge($env, $functions[$key]); + if (array_key_exists($key, $functions)) { + $envs[$key] = array_merge($env, $functions[$key]); + } else { + unset($envs[$key]); + } } sleep(count($envs) * 20); From 36665e19b15c0f4340263a1e91444f03101bed8d Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Tue, 20 Apr 2021 14:05:03 +0200 Subject: [PATCH 046/111] tests: use only latest env version --- .../Functions/FunctionsCustomServerTest.php | 66 +++++++++---------- 1 file changed, 33 insertions(+), 33 deletions(-) diff --git a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php index 85fa3c9bf6..cfa9b644b7 100644 --- a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php +++ b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php @@ -468,16 +468,16 @@ class FunctionsCustomServerTest extends Scope // 'command' => 'node index.js', // 'timeout' => 15, // ], - // 'node-15.5' => [ - // 'code' => $functionsDir.'/node.tar.gz', - // 'command' => 'node index.js', - // 'timeout' => 15, - // ], - 'php-7.4' => [ - 'code' => $functionsDir.'/php.tar.gz', - 'command' => 'php index.php', + 'node-15.5' => [ + 'code' => $functionsDir.'/node.tar.gz', + 'command' => 'node index.js', 'timeout' => 15, ], + // 'php-7.4' => [ + // 'code' => $functionsDir.'/php.tar.gz', + // 'command' => 'php index.php', + // 'timeout' => 15, + // ], 'php-8.0' => [ 'code' => $functionsDir.'/php.tar.gz', 'command' => 'php index.php', @@ -488,21 +488,21 @@ class FunctionsCustomServerTest extends Scope // 'command' => 'ruby app.rb', // 'timeout' => 15, // ], - // 'ruby-3.0' => [ - // 'code' => $functionsDir.'/ruby.tar.gz', - // 'command' => 'ruby app.rb', - // 'timeout' => 15, - // ], + 'ruby-3.0' => [ + 'code' => $functionsDir.'/ruby.tar.gz', + 'command' => 'ruby app.rb', + 'timeout' => 15, + ], // 'python-3.8' => [ // 'code' => $functionsDir.'/python.tar.gz', // 'command' => 'python main.py', // 'timeout' => 15, // ], - // 'python-3.9' => [ - // 'code' => $functionsDir.'/python.tar.gz', - // 'command' => 'python main.py', - // 'timeout' => 15, - // ], + 'python-3.9' => [ + 'code' => $functionsDir.'/python.tar.gz', + 'command' => 'python main.py', + 'timeout' => 15, + ], // 'deno-1.2' => [ // 'code' => $functionsDir.'/deno.tar.gz', // 'command' => 'deno run --allow-env index.ts', @@ -518,31 +518,31 @@ class FunctionsCustomServerTest extends Scope // 'command' => 'deno run --allow-env index.ts', // 'timeout' => 15, // ], - // 'deno-1.8' => [ - // 'code' => $functionsDir.'/deno.tar.gz', - // 'command' => 'deno run --allow-env index.ts', - // 'timeout' => 15, - // ], + 'deno-1.8' => [ + 'code' => $functionsDir.'/deno.tar.gz', + 'command' => 'deno run --allow-env index.ts', + 'timeout' => 15, + ], // 'dart-2.10' => [ // 'code' => $functionsDir.'/dart.tar.gz', // 'command' => 'dart main.dart', // 'timeout' => 15, // ], - // 'dart-2.12' => [ - // 'code' => $functionsDir.'/dart.tar.gz', - // 'command' => 'dart main.dart', - // 'timeout' => 15, - // ], + 'dart-2.12' => [ + 'code' => $functionsDir.'/dart.tar.gz', + 'command' => 'dart main.dart', + 'timeout' => 15, + ], // 'dotnet-3.1' => [ // 'code' => $functionsDir.'/dotnet-3.1.tar.gz', // 'command' => 'dotnet dotnet.dll', // 'timeout' => 15, // ], - // 'dotnet-5.0' => [ - // 'code' => $functionsDir.'/dotnet-5.0.tar.gz', - // 'command' => 'dotnet dotnet.dll', - // 'timeout' => 15, - // ] + 'dotnet-5.0' => [ + 'code' => $functionsDir.'/dotnet-5.0.tar.gz', + 'command' => 'dotnet dotnet.dll', + 'timeout' => 15, + ] ]; foreach ($envs as $key => $env) { From 56c2c039b2b8f22dda4dd47451c0de73c3a887d5 Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Tue, 20 Apr 2021 14:35:07 +0200 Subject: [PATCH 047/111] tests: remove cloud function env tests --- .../Functions/FunctionsCustomServerTest.php | 404 +++++++++--------- 1 file changed, 201 insertions(+), 203 deletions(-) diff --git a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php index cfa9b644b7..eddd3db915 100644 --- a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php +++ b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php @@ -451,235 +451,233 @@ class FunctionsCustomServerTest extends Scope return $data; } - public function testENVS():array - { + // public function testENVS():array + // { - $functionsDir = realpath(__DIR__ . '/../../../resources/functions'); - $envs = require('app/config/environments.php'); + // $functionsDir = realpath(__DIR__ . '/../../../resources/functions'); + // $envs = require('app/config/environments.php'); - /** - * Command for rebuilding code packages: - * bash tests/resources/functions/package-*.sh - */ - $functions = [ - // 'node-14.5' => [ - // 'code' => $functionsDir.'/node.tar.gz', - // 'command' => 'node index.js', - // 'timeout' => 15, - // ], - 'node-15.5' => [ - 'code' => $functionsDir.'/node.tar.gz', - 'command' => 'node index.js', - 'timeout' => 15, - ], - // 'php-7.4' => [ - // 'code' => $functionsDir.'/php.tar.gz', - // 'command' => 'php index.php', - // 'timeout' => 15, - // ], - 'php-8.0' => [ - 'code' => $functionsDir.'/php.tar.gz', - 'command' => 'php index.php', - 'timeout' => 15, - ], - // 'ruby-2.7' => [ - // 'code' => $functionsDir.'/ruby.tar.gz', - // 'command' => 'ruby app.rb', - // 'timeout' => 15, - // ], - 'ruby-3.0' => [ - 'code' => $functionsDir.'/ruby.tar.gz', - 'command' => 'ruby app.rb', - 'timeout' => 15, - ], - // 'python-3.8' => [ - // 'code' => $functionsDir.'/python.tar.gz', - // 'command' => 'python main.py', - // 'timeout' => 15, - // ], - 'python-3.9' => [ - 'code' => $functionsDir.'/python.tar.gz', - 'command' => 'python main.py', - 'timeout' => 15, - ], - // 'deno-1.2' => [ - // 'code' => $functionsDir.'/deno.tar.gz', - // 'command' => 'deno run --allow-env index.ts', - // 'timeout' => 15, - // ], - // 'deno-1.5' => [ - // 'code' => $functionsDir.'/deno.tar.gz', - // 'command' => 'deno run --allow-env index.ts', - // 'timeout' => 15, - // ], - // 'deno-1.6' => [ - // 'code' => $functionsDir.'/deno.tar.gz', - // 'command' => 'deno run --allow-env index.ts', - // 'timeout' => 15, - // ], - 'deno-1.8' => [ - 'code' => $functionsDir.'/deno.tar.gz', - 'command' => 'deno run --allow-env index.ts', - 'timeout' => 15, - ], - // 'dart-2.10' => [ - // 'code' => $functionsDir.'/dart.tar.gz', - // 'command' => 'dart main.dart', - // 'timeout' => 15, - // ], - 'dart-2.12' => [ - 'code' => $functionsDir.'/dart.tar.gz', - 'command' => 'dart main.dart', - 'timeout' => 15, - ], - // 'dotnet-3.1' => [ - // 'code' => $functionsDir.'/dotnet-3.1.tar.gz', - // 'command' => 'dotnet dotnet.dll', - // 'timeout' => 15, - // ], - 'dotnet-5.0' => [ - 'code' => $functionsDir.'/dotnet-5.0.tar.gz', - 'command' => 'dotnet dotnet.dll', - 'timeout' => 15, - ] - ]; + // /** + // * Command for rebuilding code packages: + // * bash tests/resources/functions/package-*.sh + // */ + // $functions = [ + // // 'node-14.5' => [ + // // 'code' => $functionsDir.'/node.tar.gz', + // // 'command' => 'node index.js', + // // 'timeout' => 15, + // // ], + // 'node-15.5' => [ + // 'code' => $functionsDir.'/node.tar.gz', + // 'command' => 'node index.js', + // 'timeout' => 15, + // ], + // // 'php-7.4' => [ + // // 'code' => $functionsDir.'/php.tar.gz', + // // 'command' => 'php index.php', + // // 'timeout' => 15, + // // ], + // 'php-8.0' => [ + // 'code' => $functionsDir.'/php.tar.gz', + // 'command' => 'php index.php', + // 'timeout' => 15, + // ], + // // 'ruby-2.7' => [ + // // 'code' => $functionsDir.'/ruby.tar.gz', + // // 'command' => 'ruby app.rb', + // // 'timeout' => 15, + // // ], + // 'ruby-3.0' => [ + // 'code' => $functionsDir.'/ruby.tar.gz', + // 'command' => 'ruby app.rb', + // 'timeout' => 15, + // ], + // // 'python-3.8' => [ + // // 'code' => $functionsDir.'/python.tar.gz', + // // 'command' => 'python main.py', + // // 'timeout' => 15, + // // ], + // 'python-3.9' => [ + // 'code' => $functionsDir.'/python.tar.gz', + // 'command' => 'python main.py', + // 'timeout' => 15, + // ], + // // 'deno-1.2' => [ + // // 'code' => $functionsDir.'/deno.tar.gz', + // // 'command' => 'deno run --allow-env index.ts', + // // 'timeout' => 15, + // // ], + // // 'deno-1.5' => [ + // // 'code' => $functionsDir.'/deno.tar.gz', + // // 'command' => 'deno run --allow-env index.ts', + // // 'timeout' => 15, + // // ], + // // 'deno-1.6' => [ + // // 'code' => $functionsDir.'/deno.tar.gz', + // // 'command' => 'deno run --allow-env index.ts', + // // 'timeout' => 15, + // // ], + // 'deno-1.8' => [ + // 'code' => $functionsDir.'/deno.tar.gz', + // 'command' => 'deno run --allow-env index.ts', + // 'timeout' => 15, + // ], + // // 'dart-2.10' => [ + // // 'code' => $functionsDir.'/dart.tar.gz', + // // 'command' => 'dart main.dart', + // // 'timeout' => 15, + // // ], + // 'dart-2.12' => [ + // 'code' => $functionsDir.'/dart.tar.gz', + // 'command' => 'dart main.dart', + // 'timeout' => 15, + // ], + // // 'dotnet-3.1' => [ + // // 'code' => $functionsDir.'/dotnet-3.1.tar.gz', + // // 'command' => 'dotnet dotnet.dll', + // // 'timeout' => 15, + // // ], + // 'dotnet-5.0' => [ + // 'code' => $functionsDir.'/dotnet-5.0.tar.gz', + // 'command' => 'dotnet dotnet.dll', + // 'timeout' => 15, + // ] + // ]; - foreach ($envs as $key => $env) { - if (array_key_exists($key, $functions)) { - $envs[$key] = array_merge($env, $functions[$key]); - } else { - unset($envs[$key]); - } - } + // foreach ($envs as $key => $env) { + // if (array_key_exists($key, $functions)) { + // $envs[$key] = array_merge($env, $functions[$key]); + // } else { + // unset($envs[$key]); + // } + // } - sleep(count($envs) * 20); - fwrite(STDERR, "."); + // sleep(count($envs) * 20); + // fwrite(STDERR, "."); - /** - * Test for SUCCESS - */ - $file = $this->client->call(Client::METHOD_POST, '/storage/files', array_merge([ - 'content-type' => 'multipart/form-data', - 'x-appwrite-project' => $this->getProject()['$id'], - ], $this->getHeaders()), [ - 'file' => new CURLFile(realpath(__DIR__ . '/../../../resources/logo.png'), 'image/png', 'logo.png'), - 'read' => ['*'], - 'write' => ['*'], - 'folderId' => 'xyz', - ]); + // /** + // * Test for SUCCESS + // */ + // $file = $this->client->call(Client::METHOD_POST, '/storage/files', array_merge([ + // 'content-type' => 'multipart/form-data', + // 'x-appwrite-project' => $this->getProject()['$id'], + // ], $this->getHeaders()), [ + // 'file' => new CURLFile(realpath(__DIR__ . '/../../../resources/logo.png'), 'image/png', 'logo.png'), + // 'read' => ['*'], + // 'write' => ['*'], + // 'folderId' => 'xyz', + // ]); - $this->assertEquals($file['headers']['status-code'], 201); - $this->assertNotEmpty($file['body']['$id']); + // $this->assertEquals($file['headers']['status-code'], 201); + // $this->assertNotEmpty($file['body']['$id']); - $fileId = $file['body']['$id'] ?? ''; + // $fileId = $file['body']['$id'] ?? ''; - foreach ($envs as $key => $env) { - $name = $key ?? ''; - $language = $env['name'] ?? ''; - $version = $env['version'] ?? ''; - $code = $env['code'] ?? ''; - $command = $env['command'] ?? ''; - $timeout = $env['timeout'] ?? 15; + // foreach ($envs as $key => $env) { + // $name = $key ?? ''; + // $language = $env['name'] ?? ''; + // $version = $env['version'] ?? ''; + // $code = $env['code'] ?? ''; + // $command = $env['command'] ?? ''; + // $timeout = $env['timeout'] ?? 15; - $function = $this->client->call(Client::METHOD_POST, '/functions', array_merge([ - 'content-type' => 'application/json', - 'x-appwrite-project' => $this->getProject()['$id'], - ], $this->getHeaders()), [ - 'name' => 'Test '.$name, - 'env' => $name, - 'vars' => [ - 'APPWRITE_ENDPOINT' => 'http://appwrite.test/v1', - 'APPWRITE_PROJECT' => $this->getProject()['$id'], - 'APPWRITE_SECRET' => $this->getProject()['apiKey'], - 'APPWRITE_FILEID' => $fileId, - ], - 'events' => [], - 'schedule' => '', - 'timeout' => $timeout, - ]); + // $function = $this->client->call(Client::METHOD_POST, '/functions', array_merge([ + // 'content-type' => 'application/json', + // 'x-appwrite-project' => $this->getProject()['$id'], + // ], $this->getHeaders()), [ + // 'name' => 'Test '.$name, + // 'env' => $name, + // 'vars' => [ + // 'APPWRITE_ENDPOINT' => 'http://appwrite.test/v1', + // 'APPWRITE_PROJECT' => $this->getProject()['$id'], + // 'APPWRITE_SECRET' => $this->getProject()['apiKey'], + // 'APPWRITE_FILEID' => $fileId, + // ], + // 'events' => [], + // 'schedule' => '', + // 'timeout' => $timeout, + // ]); - // var_dump('http://'.gethostbyname(trim(`hostname`)).'/v1'); + // // var_dump('http://'.gethostbyname(trim(`hostname`)).'/v1'); - $functionId = $function['body']['$id'] ?? ''; + // $functionId = $function['body']['$id'] ?? ''; - $this->assertEquals(201, $function['headers']['status-code']); + // $this->assertEquals(201, $function['headers']['status-code']); - $tag = $this->client->call(Client::METHOD_POST, '/functions/'.$functionId.'/tags', array_merge([ - 'content-type' => 'multipart/form-data', - 'x-appwrite-project' => $this->getProject()['$id'], - ], $this->getHeaders()), [ - 'command' => $command, - 'code' => new CURLFile($code, 'application/x-gzip', basename($code)), - ]); + // $tag = $this->client->call(Client::METHOD_POST, '/functions/'.$functionId.'/tags', array_merge([ + // 'content-type' => 'multipart/form-data', + // 'x-appwrite-project' => $this->getProject()['$id'], + // ], $this->getHeaders()), [ + // 'command' => $command, + // 'code' => new CURLFile($code, 'application/x-gzip', basename($code)), + // ]); - $tagId = $tag['body']['$id'] ?? ''; - $this->assertEquals(201, $tag['headers']['status-code']); + // $tagId = $tag['body']['$id'] ?? ''; + // $this->assertEquals(201, $tag['headers']['status-code']); - $tag = $this->client->call(Client::METHOD_PATCH, '/functions/'.$functionId.'/tag', array_merge([ - 'content-type' => 'application/json', - 'x-appwrite-project' => $this->getProject()['$id'], - ], $this->getHeaders()), [ - 'tag' => $tagId, - ]); + // $tag = $this->client->call(Client::METHOD_PATCH, '/functions/'.$functionId.'/tag', array_merge([ + // 'content-type' => 'application/json', + // 'x-appwrite-project' => $this->getProject()['$id'], + // ], $this->getHeaders()), [ + // 'tag' => $tagId, + // ]); - $this->assertEquals(200, $tag['headers']['status-code']); + // $this->assertEquals(200, $tag['headers']['status-code']); - $execution = $this->client->call(Client::METHOD_POST, '/functions/'.$functionId.'/executions', array_merge([ - 'content-type' => 'application/json', - 'x-appwrite-project' => $this->getProject()['$id'], - ], $this->getHeaders()), [ - 'async' => 1, - ]); + // $execution = $this->client->call(Client::METHOD_POST, '/functions/'.$functionId.'/executions', array_merge([ + // 'content-type' => 'application/json', + // 'x-appwrite-project' => $this->getProject()['$id'], + // ], $this->getHeaders()), [ + // 'async' => 1, + // ]); - $executionId = $execution['body']['$id'] ?? ''; - $this->assertEquals(201, $execution['headers']['status-code']); + // $executionId = $execution['body']['$id'] ?? ''; + // $this->assertEquals(201, $execution['headers']['status-code']); - sleep(10); + // sleep(10); - $executions = $this->client->call(Client::METHOD_GET, '/functions/'.$functionId.'/executions', array_merge([ - 'content-type' => 'application/json', - 'x-appwrite-project' => $this->getProject()['$id'], - ], $this->getHeaders())); + // $executions = $this->client->call(Client::METHOD_GET, '/functions/'.$functionId.'/executions', array_merge([ + // 'content-type' => 'application/json', + // 'x-appwrite-project' => $this->getProject()['$id'], + // ], $this->getHeaders())); - if($executions['body']['executions'][0]['status'] !== 'completed') { - var_dump($env); - var_dump($executions['body']['executions'][0]); - $stdout = ''; - $stderr = ''; - Console::execute('docker logs appwrite-worker-functions', '', $stdout, $stderr); - var_dump($stdout); - var_dump($stderr); - } + // if($executions['body']['executions'][0]['status'] !== 'completed') { + // var_dump($env); + // var_dump($executions['body']['executions'][0]); + // $stdout = ''; + // $stderr = ''; + // Console::execute('docker logs appwrite-worker-functions', '', $stdout, $stderr); + // var_dump($stdout); + // var_dump($stderr); + // } - $this->assertEquals($executions['headers']['status-code'], 200); - $this->assertEquals($executions['body']['sum'], 1); - $this->assertIsArray($executions['body']['executions']); - $this->assertCount(1, $executions['body']['executions']); - $this->assertEquals($executions['body']['executions'][0]['$id'], $executionId); - $this->assertEquals($executions['body']['executions'][0]['trigger'], 'http'); - $this->assertEquals($executions['body']['executions'][0]['status'], 'completed'); - $this->assertEquals($executions['body']['executions'][0]['exitCode'], 0); + // $this->assertEquals($executions['headers']['status-code'], 200); + // $this->assertEquals($executions['body']['sum'], 1); + // $this->assertIsArray($executions['body']['executions']); + // $this->assertCount(1, $executions['body']['executions']); + // $this->assertEquals($executions['body']['executions'][0]['$id'], $executionId); + // $this->assertEquals($executions['body']['executions'][0]['trigger'], 'http'); + // $this->assertEquals($executions['body']['executions'][0]['status'], 'completed'); + // $this->assertEquals($executions['body']['executions'][0]['exitCode'], 0); - $stdout = explode("\n", $executions['body']['executions'][0]['stdout']); + // $stdout = explode("\n", $executions['body']['executions'][0]['stdout']); - $this->assertEquals($stdout[0], $functionId); - $this->assertEquals($stdout[1], 'Test '.$name); - $this->assertEquals($stdout[2], $tagId); - $this->assertEquals($stdout[3], 'http'); - $this->assertEquals($stdout[4], $language); - $this->assertEquals($stdout[5], $version); - // $this->assertEquals($stdout[6], $fileId); - fwrite(STDERR, "."); - } + // $this->assertEquals($stdout[0], $functionId); + // $this->assertEquals($stdout[1], 'Test '.$name); + // $this->assertEquals($stdout[2], $tagId); + // $this->assertEquals($stdout[3], 'http'); + // $this->assertEquals($stdout[4], $language); + // $this->assertEquals($stdout[5], $version); + // // $this->assertEquals($stdout[6], $fileId); + // fwrite(STDERR, "."); + // } + + // return [ + // 'functionId' => $functionId, + // ]; + // } - return [ - 'functionId' => $functionId, - ]; - } - /** - * @depends testENVS - */ public function testTimeout() { $name = 'php-8.0'; From 25b03c90f8eb5655d0a2ccc6a3f83b9c10d3edec Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Wed, 21 Apr 2021 13:02:54 +0200 Subject: [PATCH 048/111] feat: introduce appwrite/php-runtimes --- app/config/environments.php | 165 -------- app/config/runtimes.php | 19 + app/controllers/api/functions.php | 2 +- app/controllers/shared/web.php | 2 +- app/controllers/web/console.php | 2 +- app/init.php | 2 +- app/views/console/functions/function.phtml | 2 +- app/views/console/functions/index.phtml | 10 +- app/views/layouts/default.phtml | 4 +- app/workers/functions.php | 26 +- composer.json | 5 + composer.lock | 65 ++- docker/environments/README.md | 13 - docker/environments/build.sh | 49 --- docker/environments/dart-2.10/Dockerfile | 9 - docker/environments/dart-2.12/Dockerfile | 9 - docker/environments/deno-1.2/Dockerfile | 11 - docker/environments/deno-1.5/Dockerfile | 11 - docker/environments/deno-1.6/Dockerfile | 11 - docker/environments/deno-1.8/Dockerfile | 11 - docker/environments/dotnet-3.1/Dockerfile | 7 - docker/environments/dotnet-5.0/Dockerfile | 7 - docker/environments/node-14.5/Dockerfile | 9 - docker/environments/node-15.5/Dockerfile | 9 - docker/environments/php-7.4/Dockerfile | 9 - docker/environments/php-8.0/Dockerfile | 9 - docker/environments/python-3.8/Dockerfile | 11 - docker/environments/python-3.9/Dockerfile | 11 - docker/environments/ruby-2.7/Dockerfile | 12 - docker/environments/ruby-3.0/Dockerfile | 12 - public/dist/scripts/app-all.js | 6 +- public/dist/scripts/app.js | 6 +- public/scripts/filters.js | 12 +- .../Functions/FunctionsCustomServerTest.php | 227 ----------- tests/resources/functions/dart.tar.gz | Bin 261057 -> 0 bytes tests/resources/functions/dart/main.dart | 26 -- tests/resources/functions/dart/pubspec.yaml | 7 - tests/resources/functions/deno.tar.gz | Bin 25983 -> 0 bytes tests/resources/functions/deno/index.ts | 23 -- tests/resources/functions/dotnet-3.1.tar.gz | Bin 328233 -> 0 bytes .../resources/functions/dotnet-3.1/Program.cs | 28 -- .../functions/dotnet-3.1/dotnet.csproj | 9 - tests/resources/functions/dotnet-5.0.tar.gz | Bin 323905 -> 0 bytes .../resources/functions/dotnet-5.0/Program.cs | 28 -- .../functions/dotnet-5.0/dotnet.csproj | 9 - tests/resources/functions/node.tar.gz | Bin 1346164 -> 0 bytes tests/resources/functions/node/index.js | 23 -- .../functions/node/package-lock.json | 376 ------------------ tests/resources/functions/node/package.json | 9 - tests/resources/functions/package-dart.sh | 13 - tests/resources/functions/package-deno.sh | 12 - .../resources/functions/package-dotnet-3.1.sh | 12 - .../resources/functions/package-dotnet-5.0.sh | 12 - tests/resources/functions/package-node.sh | 12 - tests/resources/functions/package-python.sh | 12 - tests/resources/functions/package-ruby.sh | 12 - tests/resources/functions/python.tar.gz | Bin 905134 -> 0 bytes tests/resources/functions/python/main.py | 23 -- .../functions/python/requirements.txt | 1 - tests/resources/functions/ruby.tar.gz | Bin 18239 -> 0 bytes tests/resources/functions/ruby/Gemfile | 5 - tests/resources/functions/ruby/Gemfile.lock | 16 - tests/resources/functions/ruby/app.rb | 23 -- 63 files changed, 117 insertions(+), 1349 deletions(-) delete mode 100644 app/config/environments.php create mode 100644 app/config/runtimes.php delete mode 100644 docker/environments/README.md delete mode 100644 docker/environments/build.sh delete mode 100644 docker/environments/dart-2.10/Dockerfile delete mode 100644 docker/environments/dart-2.12/Dockerfile delete mode 100644 docker/environments/deno-1.2/Dockerfile delete mode 100644 docker/environments/deno-1.5/Dockerfile delete mode 100644 docker/environments/deno-1.6/Dockerfile delete mode 100644 docker/environments/deno-1.8/Dockerfile delete mode 100644 docker/environments/dotnet-3.1/Dockerfile delete mode 100644 docker/environments/dotnet-5.0/Dockerfile delete mode 100644 docker/environments/node-14.5/Dockerfile delete mode 100644 docker/environments/node-15.5/Dockerfile delete mode 100644 docker/environments/php-7.4/Dockerfile delete mode 100644 docker/environments/php-8.0/Dockerfile delete mode 100644 docker/environments/python-3.8/Dockerfile delete mode 100644 docker/environments/python-3.9/Dockerfile delete mode 100644 docker/environments/ruby-2.7/Dockerfile delete mode 100644 docker/environments/ruby-3.0/Dockerfile delete mode 100644 tests/resources/functions/dart.tar.gz delete mode 100644 tests/resources/functions/dart/main.dart delete mode 100644 tests/resources/functions/dart/pubspec.yaml delete mode 100644 tests/resources/functions/deno.tar.gz delete mode 100644 tests/resources/functions/deno/index.ts delete mode 100644 tests/resources/functions/dotnet-3.1.tar.gz delete mode 100644 tests/resources/functions/dotnet-3.1/Program.cs delete mode 100644 tests/resources/functions/dotnet-3.1/dotnet.csproj delete mode 100644 tests/resources/functions/dotnet-5.0.tar.gz delete mode 100644 tests/resources/functions/dotnet-5.0/Program.cs delete mode 100644 tests/resources/functions/dotnet-5.0/dotnet.csproj delete mode 100644 tests/resources/functions/node.tar.gz delete mode 100644 tests/resources/functions/node/index.js delete mode 100644 tests/resources/functions/node/package-lock.json delete mode 100644 tests/resources/functions/node/package.json delete mode 100644 tests/resources/functions/package-dart.sh delete mode 100644 tests/resources/functions/package-deno.sh delete mode 100644 tests/resources/functions/package-dotnet-3.1.sh delete mode 100644 tests/resources/functions/package-dotnet-5.0.sh delete mode 100644 tests/resources/functions/package-node.sh delete mode 100644 tests/resources/functions/package-python.sh delete mode 100644 tests/resources/functions/package-ruby.sh delete mode 100644 tests/resources/functions/python.tar.gz delete mode 100644 tests/resources/functions/python/main.py delete mode 100644 tests/resources/functions/python/requirements.txt delete mode 100644 tests/resources/functions/ruby.tar.gz delete mode 100644 tests/resources/functions/ruby/Gemfile delete mode 100644 tests/resources/functions/ruby/Gemfile.lock delete mode 100644 tests/resources/functions/ruby/app.rb diff --git a/app/config/environments.php b/app/config/environments.php deleted file mode 100644 index cd3868d72c..0000000000 --- a/app/config/environments.php +++ /dev/null @@ -1,165 +0,0 @@ - [ - 'name' => 'Node.js', - 'version' => '14.5', - 'base' => 'node:14.5-alpine', - 'image' => 'appwrite/env-node-14.5:1.0.0', - 'build' => '/usr/src/code/docker/environments/node-14.5', - 'logo' => 'node.png', - 'supports' => [System::X86, System::PPC, System::ARM], - ], - 'node-15.5' => [ - 'name' => 'Node.js', - 'version' => '15.5', - 'base' => 'node:15.5-alpine', - 'image' => 'appwrite/env-node-15.5:1.0.0', - 'build' => '/usr/src/code/docker/environments/node-15.5', - 'logo' => 'node.png', - 'supports' => [System::X86, System::PPC, System::ARM], - ], - 'php-7.4' => [ - 'name' => 'PHP', - 'version' => '7.4', - 'base' => 'php:7.4-cli-alpine', - 'image' => 'appwrite/env-php-7.4:1.0.0', - 'build' => '/usr/src/code/docker/environments/php-7.4', - 'logo' => 'php.png', - 'supports' => [System::X86, System::PPC, System::ARM], - ], - 'php-8.0' => [ - 'name' => 'PHP', - 'version' => '8.0', - 'base' => 'php:8.0-cli-alpine', - 'image' => 'appwrite/env-php-8.0:1.0.0', - 'build' => '/usr/src/code/docker/environments/php-8.0', - 'logo' => 'php.png', - 'supports' => [System::X86, System::PPC, System::ARM], - ], - 'ruby-2.7' => [ - 'name' => 'Ruby', - 'version' => '2.7', - 'base' => 'ruby:2.7-alpine', - 'image' => 'appwrite/env-ruby-2.7:1.0.2', - 'build' => '/usr/src/code/docker/environments/ruby-2.7', - 'logo' => 'ruby.png', - 'supports' => [System::X86, System::PPC, System::ARM], - ], - 'ruby-3.0' => [ - 'name' => 'Ruby', - 'version' => '3.0', - 'base' => 'ruby:3.0-alpine', - 'image' => 'appwrite/env-ruby-3.0:1.0.0', - 'build' => '/usr/src/code/docker/environments/ruby-3.0', - 'logo' => 'ruby.png', - 'supports' => [System::X86, System::PPC, System::ARM], - ], - 'python-3.8' => [ - 'name' => 'Python', - 'version' => '3.8', - 'base' => 'python:3.8-alpine', - 'image' => 'appwrite/env-python-3.8:1.0.0', - 'build' => '/usr/src/code/docker/environments/python-3.8', - 'logo' => 'python.png', - 'supports' => [System::X86, System::PPC, System::ARM], - ], - 'python-3.9' => [ - 'name' => 'Python', - 'version' => '3.9', - 'base' => 'python:3.9-alpine', - 'image' => 'appwrite/env-python-3.9:1.0.0', - 'build' => '/usr/src/code/docker/environments/python-3.9', - 'logo' => 'python.png', - 'supports' => [System::X86, System::PPC, System::ARM], - ], - 'deno-1.2' => [ - 'name' => 'Deno', - 'version' => '1.2', - 'base' => 'hayd/deno:alpine-1.2.0', - 'image' => 'appwrite/env-deno-1.2:1.0.0', - 'build' => '/usr/src/code/docker/environments/deno-1.2', - 'logo' => 'deno.png', - 'supports' => [System::X86], - ], - 'deno-1.5' => [ - 'name' => 'Deno', - 'version' => '1.5', - 'base' => 'hayd/deno:alpine-1.5.0', - 'image' => 'appwrite/env-deno-1.5:1.0.0', - 'build' => '/usr/src/code/docker/environments/deno-1.5', - 'logo' => 'deno.png', - 'supports' => [System::X86], - ], - 'deno-1.6' => [ - 'name' => 'Deno', - 'version' => '1.6', - 'base' => 'hayd/deno:alpine-1.6.0', - 'image' => 'appwrite/env-deno-1.6:1.0.0', - 'build' => '/usr/src/code/docker/environments/deno-1.6', - 'logo' => 'deno.png', - 'supports' => [System::X86], - ], - 'deno-1.8' => [ - 'name' => 'Deno', - 'version' => '1.8', - 'base' => 'hayd/deno:alpine-1.8.2', - 'image' => 'appwrite/env-deno-1.8:1.0.0', - 'build' => '/usr/src/code/docker/environments/deno-1.8', - 'logo' => 'deno.png', - 'supports' => [System::X86], - ], - 'dart-2.10' => [ - 'name' => 'Dart', - 'version' => '2.10', - 'base' => 'google/dart:2.10', - 'image' => 'appwrite/env-dart-2.10:1.0.0', - 'build' => '/usr/src/code/docker/environments/dart-2.10', - 'logo' => 'dart.png', - 'supports' => [System::X86], - ], - 'dart-2.12' => [ - 'name' => 'Dart', - 'version' => '2.12', - 'base' => 'google/dart:2.12', - 'image' => 'appwrite/env-dart-2.12:1.0.0', - 'build' => '/usr/src/code/docker/environments/dart-2.12', - 'logo' => 'dart.png', - 'supports' => [System::X86], - ], - 'dotnet-3.1' => [ - 'name' => '.NET', - 'version' => '3.1', - 'base' => 'mcr.microsoft.com/dotnet/runtime:3.1-alpine', - 'image' => 'appwrite/env-dotnet-3.1:1.0.0', - 'build' => '/usr/src/code/docker/environments/dotnet-3.1', - 'logo' => 'dotnet.png', - 'supports' => [System::X86], - ], - 'dotnet-5.0' => [ - 'name' => '.NET', - 'version' => '5.0', - 'base' => 'mcr.microsoft.com/dotnet/runtime:5.0-alpine', - 'image' => 'appwrite/env-dotnet-5.0:1.0.0', - 'build' => '/usr/src/code/docker/environments/dotnet-5.0', - 'logo' => 'dotnet.png', - 'supports' => [System::X86, System::ARM], - ], -]; - -$allowList = empty(App::getEnv('_APP_FUNCTIONS_ENVS', null)) ? false : \explode(',', App::getEnv('_APP_FUNCTIONS_ENVS', null)); - -$environments = array_filter($environments, function ($environment, $key) use ($allowList) { - $isAllowed = $allowList && in_array($key, $allowList); - $isSupported = in_array(System::getArchEnum(), $environment["supports"]); - - return $allowList ? ($isAllowed && $isSupported) : $isSupported; -}, ARRAY_FILTER_USE_BOTH); - -return $environments; \ No newline at end of file diff --git a/app/config/runtimes.php b/app/config/runtimes.php new file mode 100644 index 0000000000..dd4dfb5130 --- /dev/null +++ b/app/config/runtimes.php @@ -0,0 +1,19 @@ +label('sdk.response.model', Response::MODEL_FUNCTION) ->param('name', '', new Text(128), 'Function name. Max length: 128 chars.') ->param('execute', [], new ArrayList(new Text(64)), 'An array of strings with execution permissions. By default no user is granted with any execute permissions. [learn more about permissions](/docs/permissions) and get a full list of available permissions.') - ->param('env', '', new WhiteList(array_keys(Config::getParam('environments')), true), 'Execution enviornment.') + ->param('env', '', new WhiteList(array_keys(Config::getParam('runtimes')), true), 'Execution enviornment.') ->param('vars', [], new Assoc(), 'Key-value JSON object.', true) ->param('events', [], new ArrayList(new WhiteList(array_keys(Config::getParam('events')), true)), 'Events list.', true) ->param('schedule', '', new Cron(), 'Schedule CRON syntax.', true) diff --git a/app/controllers/shared/web.php b/app/controllers/shared/web.php index 526a4dbb62..dacd2501ed 100644 --- a/app/controllers/shared/web.php +++ b/app/controllers/shared/web.php @@ -32,7 +32,7 @@ App::init(function ($utopia, $request, $response, $layout) { ['type' => 'developer', 'label' => 'Developer'], ['type' => 'admin', 'label' => 'Admin'], ]) - ->setParam('environments', Config::getParam('environments')) + ->setParam('runtimes', Config::getParam('runtimes')) ->setParam('mode', App::getMode()) ; diff --git a/app/controllers/web/console.php b/app/controllers/web/console.php index b41f1d1f86..b8b334f66d 100644 --- a/app/controllers/web/console.php +++ b/app/controllers/web/console.php @@ -370,7 +370,7 @@ App::get('/console/functions') $page = new View(__DIR__.'/../../views/console/functions/index.phtml'); $page - ->setParam('environments', Config::getParam('environments')) + ->setParam('runtimes', Config::getParam('runtimes')) ; $layout diff --git a/app/init.php b/app/init.php index c9ff809b8f..ee68db4bc9 100644 --- a/app/init.php +++ b/app/init.php @@ -78,7 +78,7 @@ Config::load('events', __DIR__.'/config/events.php'); Config::load('providers', __DIR__.'/config/providers.php'); Config::load('platforms', __DIR__.'/config/platforms.php'); Config::load('collections', __DIR__.'/config/collections.php'); -Config::load('environments', __DIR__.'/config/environments.php'); +Config::load('runtimes', __DIR__.'/config/runtimes.php'); Config::load('roles', __DIR__.'/config/roles.php'); // User roles and scopes Config::load('scopes', __DIR__.'/config/scopes.php'); // User roles and scopes Config::load('services', __DIR__.'/config/services.php'); // List of services diff --git a/app/views/console/functions/function.phtml b/app/views/console/functions/function.phtml index 15ba114350..15d4bf9e00 100644 --- a/app/views/console/functions/function.phtml +++ b/app/views/console/functions/function.phtml @@ -46,7 +46,7 @@ $usageStatsEnabled = $this->getParam('usageStatsEnabled',true);
- Function Env. + Function Env.

diff --git a/app/views/console/functions/index.phtml b/app/views/console/functions/index.phtml index 2aec5b6493..5951ad51cf 100644 --- a/app/views/console/functions/index.phtml +++ b/app/views/console/functions/index.phtml @@ -1,5 +1,5 @@ getParam('environments', []); +$runtimes = $this->getParam('runtimes', []); ?>

@@ -40,7 +40,7 @@ $environments = $this->getParam('environments', []);