Skip to content

Commit

Permalink
chore: update python requirements and dependencies (#1028)
Browse files Browse the repository at this point in the history
* bump python 3.12->3.13

* bump dependencies

* bump min py 3.8->3.9

* downgrade libs for py3.9 compatibility
  • Loading branch information
AndreyNikiforov authored Dec 28, 2024
1 parent b700382 commit db29b95
Show file tree
Hide file tree
Showing 32 changed files with 137 additions and 129 deletions.
2 changes: 1 addition & 1 deletion .devcontainer/python/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
{
"name": "Python 3",
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
"image": "mcr.microsoft.com/devcontainers/python:3.12",
"image": "mcr.microsoft.com/devcontainers/python:3.13",
"features": {
"ghcr.io/devcontainers/features/docker-in-docker:2": {}
},
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/build-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ jobs:
id: pages
uses: actions/configure-pages@v5

- name: Set up Python 3.12
- name: Set up Python 3.13
uses: actions/setup-python@v5
with:
python-version: '3.12'
python-version: '3.13'

- name: Install Dev dependencies
run: |
Expand Down
50 changes: 25 additions & 25 deletions .github/workflows/build-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ jobs:
path: |
src/foundation
- name: Set up Python 3.12
- name: Set up Python 3.13
uses: actions/setup-python@v5
with:
python-version: '3.12'
python-version: '3.13'

- name: Install Dev dependencies
run: |
Expand Down Expand Up @@ -64,10 +64,10 @@ jobs:
path: |
src/foundation
- name: Set up Python 3.12
- name: Set up Python 3.13
uses: actions/setup-python@v5
with:
python-version: '3.12'
python-version: '3.13'

- name: Install Dev dependencies
run: >
Expand Down Expand Up @@ -105,7 +105,7 @@ jobs:
- name: Run version
uses: addnab/docker-run-action@v3
with:
image: python:3.12-alpine3.18
image: python:3.13-alpine3.19
shell: sh
options: -v ${{ github.workspace }}:/work
run: >
Expand Down Expand Up @@ -144,10 +144,10 @@ jobs:
path: |
src/foundation
- name: Set up Python 3.12
- name: Set up Python 3.13
uses: actions/setup-python@v5
with:
python-version: '3.12'
python-version: '3.13'

- name: Install Dev dependencies
run: |
Expand Down Expand Up @@ -276,10 +276,10 @@ jobs:
path: |
dist
- name: Set up Python 3.12
- name: Set up Python 3.13
uses: actions/setup-python@v5
with:
python-version: '3.12'
python-version: '3.13'

- name: Install Dev dependencies
run: |
Expand Down Expand Up @@ -317,10 +317,10 @@ jobs:
path: |
dist
- name: Set up Python 3.12
- name: Set up Python 3.13
uses: actions/setup-python@v5
with:
python-version: '3.12'
python-version: '3.13'

- name: Install Dev dependencies
run: |
Expand Down Expand Up @@ -357,10 +357,10 @@ jobs:
path: |
dist
- name: Set up Python 3.12
- name: Set up Python 3.13
uses: actions/setup-python@v5
with:
python-version: '3.12'
python-version: '3.13'

- name: Install Dev dependencies
run: |
Expand Down Expand Up @@ -397,10 +397,10 @@ jobs:
path: |
dist
- name: Set up Python 3.12
- name: Set up Python 3.13
uses: actions/setup-python@v5
with:
python-version: '3.12'
python-version: '3.13'

- name: Install Dev dependencies
run: |
Expand Down Expand Up @@ -522,10 +522,10 @@ jobs:
path: |
src/foundation
- name: Set up Python 3.12
- name: Set up Python 3.13
uses: actions/setup-python@v5
with:
python-version: '3.12'
python-version: '3.13'

- name: Install Dev dependencies
run: |
Expand Down Expand Up @@ -564,10 +564,10 @@ jobs:
path: |
src/foundation
- name: Set up Python 3.12
- name: Set up Python 3.13
uses: actions/setup-python@v5
with:
python-version: '3.12'
python-version: '3.13'

- name: Install Dev dependencies
run: |
Expand Down Expand Up @@ -680,8 +680,8 @@ jobs:
matrix:
image:
- [
"python3_12", #variant name
"python:3.12", #image
"python3_13", #variant name
"python:3.13", #image
]
# apt-get does not work for debian 6 anymore
# - [
Expand Down Expand Up @@ -898,8 +898,8 @@ jobs:
matrix:
image:
- [
"python3_12_alpine3_18", #variant name
"python:3.12-alpine3.18", #image
"python3_13_alpine3_19", #variant name
"python:3.13-alpine3.19", #image
]
- [
"alpine_3_20", #variant name
Expand Down Expand Up @@ -3774,10 +3774,10 @@ jobs:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Python 3.12
- name: Set up Python 3.13
uses: actions/setup-python@v5
with:
python-version: '3.12'
python-version: '3.13'

- name: Make folder for artifacts
run: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,10 @@ jobs:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Python 3.12
- name: Set up Python 3.13
uses: actions/setup-python@v5
with:
python-version: '3.12'
python-version: '3.13'

- name: Install Dev dependencies
run: |
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/quality-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
runs-on: ubuntu-20.04
strategy:
matrix:
python-version: [3.8, 3.9, '3.10', 3.11, 3.12]
python-version: ['3.9', '3.10', '3.11', '3.12', '3.13']
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
Expand All @@ -54,7 +54,7 @@ jobs:
runs-on: ubuntu-20.04
strategy:
matrix:
python-version: [3.8, 3.9, '3.10', 3.11, 3.12]
python-version: ['3.9', '3.10', '3.11', '3.12', '3.13']
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
Expand All @@ -80,7 +80,7 @@ jobs:
runs-on: ubuntu-20.04
strategy:
matrix:
python-version: [3.8, 3.9, '3.10', 3.11, 3.12]
python-version: ['3.9', '3.10', '3.11', '3.12', '3.13']
steps:
- name: Install Locales for Tests
run: |
Expand Down Expand Up @@ -119,7 +119,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: [3.12]
python-version: [3.13]
os:
- "macos-13"
- "macos-14"
Expand Down
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

## Unreleased

- chore: bump max/default python version 3.12->3.13
- chore: bump min python version 3.8->3.9
- fix: fallback to old raw password auth if srp auth fails [#975](https://github.com/icloud-photos-downloader/icloud_photos_downloader/issues/975)

## 1.25.0 (2024-12-03)
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.build
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
# arm7l instead of v6 issue: https://stackoverflow.com/questions/78535054/how-do-you-docker-buildx-build-for-arm-v6-on-qemu-emulated-platforms-that-pres

# map source image to base
FROM python:3.12 AS base
FROM python:3.13 AS base
ARG TARGETARCH
ARG TARGETVARIANT
ENV DEBIAN_FRONTEND=noninteractive
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.build-musl
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
# rust links from https://forge.rust-lang.org/infra/other-installation-methods.html#standalone-installers

# map source image to base
FROM python:3.12-alpine3.19 AS base
FROM python:3.13-alpine3.19 AS base
ARG TARGETARCH
ARG TARGETVARIANT
WORKDIR /app
Expand Down
4 changes: 2 additions & 2 deletions binary_dist/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[build-system]
requires = [
"setuptools>=68.0.0,<69",
"wheel>=0.40.0,<0.41",
"setuptools>=75.6.0,<76",
"wheel>=0.45.1,<0.46",
]
build-backend = "setuptools.build_meta"

Expand Down
78 changes: 41 additions & 37 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[build-system]
requires = [
"setuptools==69.0.2",
"wheel==0.42.0",
"setuptools==75.6.0",
"wheel==0.45.1",
]
build-backend = "setuptools.build_meta"

Expand All @@ -10,7 +10,7 @@ version="1.25.0"
name = "icloudpd"
description = "icloudpd is a command-line tool to download photos and videos from iCloud."
readme = "README_PYPI.md"
requires-python = ">=3.8,<3.13"
requires-python = ">=3.9,<3.14"
keywords = ["icloud", "photo"]
license = {file="LICENSE.md"}
authors=[
Expand All @@ -24,60 +24,60 @@ classifiers = [
]
dependencies = [
"requests==2.31.0",
"schema==0.7.5",
"click==8.1.6",
"tqdm==4.66.4",
"schema==0.7.7",
"click==8.1.8",
"tqdm==4.67.1",
"piexif==1.1.3",
"python-dateutil==2.9.0.post0",
"urllib3==1.26.16",
"typing_extensions==4.11.0",
"Flask==3.0.3",
"waitress==3.0.0",
"urllib3==1.26.20",
"typing_extensions==4.12.2",
"Flask==3.1.0",
"waitress==3.0.2",
# from pyicloud_ipd
"six==1.16.0",
"tzlocal==5.1",
"pytz==2024.1",
"certifi==2022.12.7",
"keyring==25.2.1",
"keyrings-alt==5.0.1",
"six==1.17.0",
"tzlocal==5.2",
"pytz==2024.2",
"certifi==2024.12.14",
"keyring==25.6.0",
"keyrings-alt==5.0.2",
"srp==1.0.22",
]

[project.optional-dependencies]
dev = [
"twine==5.1.1",
"pyinstaller==6.7.0",
"wheel==0.42.0",
"furo==2024.5.6",
"Sphinx==7.3.7",
"sphinx-autobuild==2024.4.16",
"pyinstaller==6.11.1",
"wheel==0.45.1",
"furo==2024.8.6",
"Sphinx==7.4.7",
"sphinx-autobuild==2024.10.3",
"myst-parser==3.0.1"
]
devlinux = [
"auditwheel==5.4.0",
"auditwheel==6.1.0",
#"staticx==0.14.1",
"scons==4.8.0"
"scons==4.8.1"
]
test = [
"pytest==7.4.3",
"pytest==8.3.4",
"mock==5.1.0",
"freezegun==1.5.1",
"vcrpy==6.0.1",
"pytest-cov==4.1.0",
"ruff==0.5.0",
"vcrpy==6.0.2",
"pytest-cov==5.0.0",
"ruff==0.8.4",
"coveralls==3.3.1",
"pytest-timeout==2.1.0",
"pytest-xdist==3.3.1",
"mypy==1.10.1",
"types-python-dateutil==2.9.0.20241003",
"types-pytz==2024.1.0.20240417",
"pytest-timeout==2.3.1",
"pytest-xdist==3.6.1",
"mypy==1.14.0",
"types-python-dateutil==2.9.0.20241206",
"types-pytz==2024.2.0.20241221",
"types-tzlocal==5.1.0.1",
"types-requests==2.31.0.2",
"types-six==1.16.0",
"types-urllib3==1.26.16",
"types-tqdm==4.66.0.20240417",
"types-mock==5.1.0.1",
"types-waitress==3.0.0.20240423",
"types-six==1.17.0.20241205",
"types-urllib3==1.26.25.14",
"types-tqdm==4.67.0.20241221",
"types-mock==5.1.0.20240425",
"types-waitress==3.0.1.20241117",
]

[project.urls]
Expand Down Expand Up @@ -133,5 +133,9 @@ select = [
ignore = [
# long lines
"E501",
# lower case types
"UP006",
# deprecated typing namespace
"UP035",
]

2 changes: 1 addition & 1 deletion scripts/type_check
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/usr/bin/env bash
set -euo pipefail
echo "Running mypy..."
python3 -m mypy src tests --strict --python-version 3.8
python3 -m mypy src tests --strict --python-version 3.9
# --strict-equality --warn-return-any --disallow-any-generics --disallow-untyped-defs --disallow-untyped-calls --check-untyped-defs
Loading

0 comments on commit db29b95

Please sign in to comment.