Skip to content

Commit

Permalink
Merge pull request #441 from codemagic-ci-cd/improvement/support-pyth…
Browse files Browse the repository at this point in the history
…on3.13

Support Python v3.13
  • Loading branch information
mohammedbabelly20 authored Nov 21, 2024
2 parents dcda8b5 + b234000 commit ade2d13
Show file tree
Hide file tree
Showing 11 changed files with 105 additions and 210 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/run-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:

strategy:
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"]

steps:
- uses: actions/checkout@v4
Expand Down
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
Version 0.55.0
-------------
Changes in this release are from [PR #441](https://github.com/codemagic-ci-cd/cli-tools/pull/441).

**Development**
- **Breaking**: Deprecate Python 3.7, and Python 3.8 is now the minimum version of Python required.
- Add support to Python 3.13.
- Update `cffi` version to be compatible with latest version.
- Add Python 3.13 to GitHub Actions test matrix.

Version 0.54.4
-------------

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ and can be installed and updated using [pip](https://pip.pypa.io/en/stable/getti
python -m pip install codemagic-cli-tools
```

The package requires Python version 3.7+.
The package requires Python version 3.8+.

# Command line usage

Expand Down
265 changes: 85 additions & 180 deletions poetry.lock

Large diffs are not rendered by default.

5 changes: 2 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "codemagic-cli-tools"
version = "0.54.4"
version = "0.55.0"
description = "CLI tools used in Codemagic builds"
readme = "README.md"
authors = [
Expand Down Expand Up @@ -35,7 +35,7 @@ universal-apk = "codemagic.tools:UniversalApkGenerator.invoke_cli"
xcode-project = "codemagic.tools:XcodeProject.invoke_cli"

[tool.poetry.dependencies]
python = "^3.7"
python = "^3.8"
cryptography = ">= 38.0.0"
google-api-python-client = ">= 2.84.0"
httplib2 = ">= 0.19.0"
Expand All @@ -55,7 +55,6 @@ pytest = "*"
pytest-cov = "*"
ruff = "*"
types-requests = "*"
typing-extensions = "*"

[build-system]
requires = ["poetry-core>=1.0.0"]
Expand Down
2 changes: 1 addition & 1 deletion src/codemagic/__version__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
__title__ = "codemagic-cli-tools"
__description__ = "CLI tools used in Codemagic builds"
__version__ = "0.54.4.dev"
__version__ = "0.55.0.dev"
__url__ = "https://github.com/codemagic-ci-cd/cli-tools"
__licence__ = "GNU General Public License v3.0"
20 changes: 1 addition & 19 deletions src/codemagic/apple/app_store_connect/resource_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
R2 = TypeVar("R2", bound=Resource)

if TYPE_CHECKING:
from typing_extensions import Protocol
from typing import Protocol

from codemagic.apple import AppStoreConnectApiClient

Expand Down Expand Up @@ -55,24 +55,6 @@ class ModifyingResourceManager(PResourceManager[R_co], Protocol):
def modify(self, ref: ResourceReference, **update_params) -> R_co:
...

else:
# TODO: Once Python 3.7 support is removed and we have Protocols
# available in runtime, then those can be removed.
class CreatingResourceManager(Generic[R]):
...

class ReadingResourceManager(Generic[R]):
...

class ListingResourceManager(Generic[R]):
...

class DeletingResourceManager(Generic[R]):
...

class ModifyingResourceManager(Generic[R]):
...


class ResourceManager(Generic[R], metaclass=abc.ABCMeta):
class Filter:
Expand Down
3 changes: 1 addition & 2 deletions src/codemagic/cli/cli_app.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,7 @@ def assert_never(arg) -> NoReturn: # type: ignore

if TYPE_CHECKING:
from argparse import _SubParsersAction as SubParsersAction

from typing_extensions import Literal
from typing import Literal


class ArgumentValueEncodingError(Exception):
Expand Down
2 changes: 1 addition & 1 deletion src/codemagic/models/certificate_p12_exporter.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
from codemagic.mixins import StringConverterMixin

if TYPE_CHECKING:
from typing_extensions import Literal
from typing import Literal

from .certificate import Certificate
from .private_key import PrivateKey
Expand Down
2 changes: 1 addition & 1 deletion src/codemagic/models/xctests/xcresulttool.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
from codemagic.models import Xcode

if TYPE_CHECKING:
from typing_extensions import Literal
from typing import Literal

from codemagic.cli import CliApp

Expand Down
2 changes: 1 addition & 1 deletion src/codemagic/tools/keychain.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
from codemagic.models import Certificate

if TYPE_CHECKING:
from typing_extensions import Literal
from typing import Literal


class Seconds(int):
Expand Down

0 comments on commit ade2d13

Please sign in to comment.