Skip to content

Commit 532ff5f

Browse files
committed
fix: deprecate support for python 3.8
1 parent e0a430a commit 532ff5f

File tree

3 files changed

+39
-4
lines changed

3 files changed

+39
-4
lines changed

.github/workflows/tests.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,10 @@ jobs:
3636
Node20,
3737
PHP80,
3838
PHP83,
39-
Python38,
4039
Python39,
4140
Python310,
41+
Python311,
42+
Python312,
4243
Ruby27,
4344
Ruby30,
4445
Ruby31,

tests/Python38Test.php renamed to tests/Python311Test.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
namespace Tests;
44

5-
class Python38Test extends Base
5+
class Python311Test extends Base
66
{
77
protected string $sdkName = 'python';
88
protected string $sdkPlatform = 'server';
@@ -14,10 +14,10 @@ class Python38Test extends Base
1414
protected array $build = [
1515
'cp tests/languages/python/tests.py tests/sdks/python/test.py',
1616
'echo "" > tests/sdks/python/__init__.py',
17-
'docker run --rm -v $(pwd):/app -w /app --env PIP_TARGET=tests/sdks/python/vendor python:3.8-alpine pip install -r tests/sdks/python/requirements.txt --upgrade',
17+
'docker run --rm -v $(pwd):/app -w /app --env PIP_TARGET=tests/sdks/python/vendor python:3.11-alpine pip install -r tests/sdks/python/requirements.txt --upgrade',
1818
];
1919
protected string $command =
20-
'docker run --network="mockapi" --rm -v $(pwd):/app -w /app --env PIP_TARGET=tests/sdks/python/vendor --env PYTHONPATH=tests/sdks/python/vendor python:3.8-alpine python tests/sdks/python/test.py';
20+
'docker run --network="mockapi" --rm -v $(pwd):/app -w /app --env PIP_TARGET=tests/sdks/python/vendor --env PYTHONPATH=tests/sdks/python/vendor python:3.11-alpine python tests/sdks/python/test.py';
2121

2222
protected array $expectedOutput = [
2323
...Base::FOO_RESPONSES,

tests/Python312Test.php

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
<?php
2+
3+
namespace Tests;
4+
5+
class Python312Test extends Base
6+
{
7+
protected string $sdkName = 'python';
8+
protected string $sdkPlatform = 'server';
9+
protected string $sdkLanguage = 'python';
10+
protected string $version = '0.0.1';
11+
12+
protected string $language = 'python';
13+
protected string $class = 'Appwrite\SDK\Language\Python';
14+
protected array $build = [
15+
'cp tests/languages/python/tests.py tests/sdks/python/test.py',
16+
'echo "" > tests/sdks/python/__init__.py',
17+
'docker run --rm -v $(pwd):/app -w /app --env PIP_TARGET=tests/sdks/python/vendor python:3.12-alpine pip install -r tests/sdks/python/requirements.txt --upgrade',
18+
];
19+
protected string $command =
20+
'docker run --network="mockapi" --rm -v $(pwd):/app -w /app --env PIP_TARGET=tests/sdks/python/vendor --env PYTHONPATH=tests/sdks/python/vendor python:3.12-alpine python tests/sdks/python/test.py';
21+
22+
protected array $expectedOutput = [
23+
...Base::FOO_RESPONSES,
24+
...Base::BAR_RESPONSES,
25+
...Base::GENERAL_RESPONSES,
26+
...Base::UPLOAD_RESPONSES,
27+
...Base::ENUM_RESPONSES,
28+
...Base::EXCEPTION_RESPONSES,
29+
...Base::OAUTH_RESPONSES,
30+
...Base::QUERY_HELPER_RESPONSES,
31+
...Base::PERMISSION_HELPER_RESPONSES,
32+
...Base::ID_HELPER_RESPONSES
33+
];
34+
}

0 commit comments

Comments
 (0)