Skip to content

Commit

Permalink
Upgrade to SDK version 1.38.0.
Browse files Browse the repository at this point in the history
  • Loading branch information
Dmitry committed Nov 12, 2022
1 parent 6d65394 commit b13f69a
Show file tree
Hide file tree
Showing 20 changed files with 527 additions and 72 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,19 +34,19 @@ jobs:

- name: Download PHP Installer
run: |
php -r "copy('https://raw.githubusercontent.com/radianceteam/ton-client-php-ext/1.37.2/installer.php', 'installer.php');"
php -r "copy('https://raw.githubusercontent.com/radianceteam/ton-client-php-ext/1.38.0/installer.php', 'installer.php');"
php -r "if (hash_file('sha384', 'installer.php') === '03586e200bc1c87f000c5a0eea27aa688eb451a5b946579205ca918bbffda7234359e2d0e176aa53e841c6a77b8de959') { echo 'Installer verified'; } else { echo 'Installer corrupt'; } echo PHP_EOL;"
- name: Install PHP Extension (Windows)
if: matrix.operating-system == 'windows-2019'
run: php installer.php -v 1.37.2
run: php installer.php -v 1.38.0

- name: Install PHP Extension (Ubuntu/Mac)
if: matrix.operating-system != 'windows-2019'
run: sudo php installer.php -v 1.37.2
run: sudo php installer.php -v 1.38.0

- name: Test PHP Extension
run: php installer.php -v 1.37.2 -T
run: php installer.php -v 1.38.0 -T

- name: Check PHP Extensions
run: php -m
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -141,15 +141,15 @@ Use [radianceteam/ton-client-php](https://hub.docker.com/r/radianceteam/ton-clie
as a base image in your `Dockerfile`:

```bash
FROM radianceteam/ton-client-php:1.37.2-php7.4-cli
FROM radianceteam/ton-client-php:1.38.0-php7.4-cli
COPY . /usr/src/myapp
WORKDIR /usr/src/myapp
CMD [ "php", "./your-script.php" ]
```

Basically, do anything you can do with the [original PHP image](https://hub.docker.com/_/php)
by just replacing `FROM php:<PHP_VERSION>-<PHP_IMAGE_VARIANT>` with
`FROM radianceteam/ton-client-php:1.37.2-php<PHP_VERSION>-<PHP_IMAGE_VARIANT>`.
`FROM radianceteam/ton-client-php:1.38.0-php<PHP_VERSION>-<PHP_IMAGE_VARIANT>`.

Note: only `cli`, `fpm` and `zts` variants are supported ATM.

Expand Down
19 changes: 13 additions & 6 deletions api.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "1.37.2",
"version": "1.38.0",
"modules": [
{
"name": "client",
Expand Down Expand Up @@ -365,7 +365,7 @@
"optional_inner": {
"type": "String"
},
"summary": "**This field is deprecated, but left for backward-compatibility.** DApp Server public address.",
"summary": "**This field is deprecated, but left for backward-compatibility.** Evernode endpoint.",
"description": null
},
{
Expand All @@ -377,8 +377,8 @@
"type": "String"
}
},
"summary": "List of DApp Server addresses.",
"description": "Any correct URL format can be specified, including IP addresses. This parameter is prevailing over `server_address`.\nCheck the full list of [supported network endpoints](../ton-os-api/networks.md)."
"summary": "List of Evernode endpoints.",
"description": "Any correct URL format can be specified, including IP addresses. This parameter is prevailing over `server_address`.\nCheck the full list of [supported network endpoints](https://docs.everos.dev/ever-sdk/reference/ever-os-api/networks)."
},
{
"name": "network_retries_count",
Expand Down Expand Up @@ -539,8 +539,8 @@
"optional_inner": {
"type": "String"
},
"summary": "Access key to GraphQL API.",
"description": "You can specify here Basic Auth secret (Evercloud project secret) in hex string\nor serialized JWT in base64 string.\nWill be passed on as Authorization: Basic ... or Authorization: Bearer ... header."
"summary": "Access key to GraphQL API (Project secret)",
"description": null
}
],
"summary": null,
Expand Down Expand Up @@ -11303,6 +11303,13 @@
"value": "614",
"summary": null,
"description": null
},
{
"name": "Unauthorized",
"type": "Number",
"value": "615",
"summary": null,
"description": null
}
],
"summary": null,
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"require": {
"php": ">=7.4",
"ext-json": "*",
"ext-ton_client": ">=1.37.2",
"ext-ton_client": ">=1.38.0",
"psr/log": "^1.1"
},
"scripts": {
Expand Down
50 changes: 27 additions & 23 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions docker/7.4/cli/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM php:7.4-cli

RUN php -r "copy('https://raw.githubusercontent.com/radianceteam/ton-client-php-ext/1.37.2/installer.php', 'installer.php');"
RUN php -r "copy('https://raw.githubusercontent.com/radianceteam/ton-client-php-ext/1.38.0/installer.php', 'installer.php');"
RUN php -r "if (hash_file('sha384', 'installer.php') === '03586e200bc1c87f000c5a0eea27aa688eb451a5b946579205ca918bbffda7234359e2d0e176aa53e841c6a77b8de959') { echo 'Installer verified'; } else { echo 'Installer corrupt'; exit(1); } echo PHP_EOL;"
RUN php installer.php -v 1.37.2
RUN php installer.php -v 1.37.2 -T
RUN php installer.php -v 1.38.0
RUN php installer.php -v 1.38.0 -T
RUN rm installer.php
6 changes: 3 additions & 3 deletions docker/7.4/fpm/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM php:7.4-fpm

RUN php -r "copy('https://raw.githubusercontent.com/radianceteam/ton-client-php-ext/1.37.2/installer.php', 'installer.php');"
RUN php -r "copy('https://raw.githubusercontent.com/radianceteam/ton-client-php-ext/1.38.0/installer.php', 'installer.php');"
RUN php -r "if (hash_file('sha384', 'installer.php') === '03586e200bc1c87f000c5a0eea27aa688eb451a5b946579205ca918bbffda7234359e2d0e176aa53e841c6a77b8de959') { echo 'Installer verified'; } else { echo 'Installer corrupt'; exit(1); } echo PHP_EOL;"
RUN php installer.php -v 1.37.2
RUN php installer.php -v 1.37.2 -T
RUN php installer.php -v 1.38.0
RUN php installer.php -v 1.38.0 -T
RUN rm installer.php
6 changes: 3 additions & 3 deletions docker/7.4/zts/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM php:7.4-zts

RUN php -r "copy('https://raw.githubusercontent.com/radianceteam/ton-client-php-ext/1.37.2/installer.php', 'installer.php');"
RUN php -r "copy('https://raw.githubusercontent.com/radianceteam/ton-client-php-ext/1.38.0/installer.php', 'installer.php');"
RUN php -r "if (hash_file('sha384', 'installer.php') === '03586e200bc1c87f000c5a0eea27aa688eb451a5b946579205ca918bbffda7234359e2d0e176aa53e841c6a77b8de959') { echo 'Installer verified'; } else { echo 'Installer corrupt'; exit(1); } echo PHP_EOL;"
RUN php installer.php -v 1.37.2
RUN php installer.php -v 1.37.2 -T
RUN php installer.php -v 1.38.0
RUN php installer.php -v 1.38.0 -T
RUN rm installer.php
6 changes: 3 additions & 3 deletions docker/8.0/cli/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM php:8.0-cli

RUN php -r "copy('https://raw.githubusercontent.com/radianceteam/ton-client-php-ext/1.37.2/installer.php', 'installer.php');"
RUN php -r "copy('https://raw.githubusercontent.com/radianceteam/ton-client-php-ext/1.38.0/installer.php', 'installer.php');"
RUN php -r "if (hash_file('sha384', 'installer.php') === '03586e200bc1c87f000c5a0eea27aa688eb451a5b946579205ca918bbffda7234359e2d0e176aa53e841c6a77b8de959') { echo 'Installer verified'; } else { echo 'Installer corrupt'; exit(1); } echo PHP_EOL;"
RUN php installer.php -v 1.37.2
RUN php installer.php -v 1.37.2 -T
RUN php installer.php -v 1.38.0
RUN php installer.php -v 1.38.0 -T
RUN rm installer.php
6 changes: 3 additions & 3 deletions docker/8.0/fpm/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM php:8.0-fpm

RUN php -r "copy('https://raw.githubusercontent.com/radianceteam/ton-client-php-ext/1.37.2/installer.php', 'installer.php');"
RUN php -r "copy('https://raw.githubusercontent.com/radianceteam/ton-client-php-ext/1.38.0/installer.php', 'installer.php');"
RUN php -r "if (hash_file('sha384', 'installer.php') === '03586e200bc1c87f000c5a0eea27aa688eb451a5b946579205ca918bbffda7234359e2d0e176aa53e841c6a77b8de959') { echo 'Installer verified'; } else { echo 'Installer corrupt'; exit(1); } echo PHP_EOL;"
RUN php installer.php -v 1.37.2
RUN php installer.php -v 1.37.2 -T
RUN php installer.php -v 1.38.0
RUN php installer.php -v 1.38.0 -T
RUN rm installer.php
6 changes: 3 additions & 3 deletions docker/8.0/zts/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM php:8.0-zts

RUN php -r "copy('https://raw.githubusercontent.com/radianceteam/ton-client-php-ext/1.37.2/installer.php', 'installer.php');"
RUN php -r "copy('https://raw.githubusercontent.com/radianceteam/ton-client-php-ext/1.38.0/installer.php', 'installer.php');"
RUN php -r "if (hash_file('sha384', 'installer.php') === '03586e200bc1c87f000c5a0eea27aa688eb451a5b946579205ca918bbffda7234359e2d0e176aa53e841c6a77b8de959') { echo 'Installer verified'; } else { echo 'Installer corrupt'; exit(1); } echo PHP_EOL;"
RUN php installer.php -v 1.37.2
RUN php installer.php -v 1.37.2 -T
RUN php installer.php -v 1.38.0
RUN php installer.php -v 1.38.0 -T
RUN rm installer.php
20 changes: 3 additions & 17 deletions src/TON/Client/NetworkConfig.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ class NetworkConfig implements JsonSerializable

/**
* Any correct URL format can be specified, including IP addresses. This parameter is prevailing over `server_address`.
* Check the full list of [supported network endpoints](../ton-os-api/networks.md).
* Check the full list of [supported network endpoints](https://docs.everos.dev/ever-sdk/reference/ever-os-api/networks).
*/
private ?array $_endpoints;

Expand Down Expand Up @@ -87,12 +87,6 @@ class NetworkConfig implements JsonSerializable
* Must be specified in milliseconds. Default is 5000 (5 sec).
*/
private ?int $_nextRempStatusTimeout;

/**
* You can specify here Basic Auth secret (Evercloud project secret) in hex string
* or serialized JWT in base64 string.
* Will be passed on as Authorization: Basic ... or Authorization: Bearer ... header.
*/
private ?string $_accessKey;

public function __construct(?array $dto = null)
Expand Down Expand Up @@ -124,7 +118,7 @@ public function getServerAddress(): ?string

/**
* Any correct URL format can be specified, including IP addresses. This parameter is prevailing over `server_address`.
* Check the full list of [supported network endpoints](../ton-os-api/networks.md).
* Check the full list of [supported network endpoints](https://docs.everos.dev/ever-sdk/reference/ever-os-api/networks).
*/
public function getEndpoints(): ?array
{
Expand Down Expand Up @@ -255,11 +249,6 @@ public function getNextRempStatusTimeout(): ?int
return $this->_nextRempStatusTimeout;
}

/**
* You can specify here Basic Auth secret (Evercloud project secret) in hex string
* or serialized JWT in base64 string.
* Will be passed on as Authorization: Basic ... or Authorization: Bearer ... header.
*/
public function getAccessKey(): ?string
{
return $this->_accessKey;
Expand All @@ -276,7 +265,7 @@ public function setServerAddress(?string $serverAddress): self

/**
* Any correct URL format can be specified, including IP addresses. This parameter is prevailing over `server_address`.
* Check the full list of [supported network endpoints](../ton-os-api/networks.md).
* Check the full list of [supported network endpoints](https://docs.everos.dev/ever-sdk/reference/ever-os-api/networks).
* @return self
*/
public function setEndpoints(?array $endpoints): self
Expand Down Expand Up @@ -440,9 +429,6 @@ public function setNextRempStatusTimeout(?int $nextRempStatusTimeout): self
}

/**
* You can specify here Basic Auth secret (Evercloud project secret) in hex string
* or serialized JWT in base64 string.
* Will be passed on as Authorization: Basic ... or Authorization: Bearer ... header.
* @return self
*/
public function setAccessKey(?string $accessKey): self
Expand Down
1 change: 1 addition & 0 deletions src/TON/Net/NetErrorCode.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,5 @@ final class NetErrorCode
public const NoEndpointsProvided = 612;
public const GraphqlWebsocketInitError = 613;
public const NetworkModuleResumed = 614;
public const Unauthorized = 615;
}
Loading

0 comments on commit b13f69a

Please sign in to comment.