Skip to content

Commit

Permalink
bump v1.17.1 (#745)
Browse files Browse the repository at this point in the history
  • Loading branch information
AndreyNikiforov authored Dec 21, 2023
1 parent 548769e commit 5594317
Show file tree
Hide file tree
Showing 8 changed files with 1,307 additions and 1,305 deletions.
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

## 1.17.1 (2023-12-20)

- fix: main macos binary failing [#668](https://github.com/icloud-photos-downloader/icloud_photos_downloader/issues/668) [#700](https://github.com/icloud-photos-downloader/icloud_photos_downloader/issues/700)
- fix: debian glibc error [#741](https://github.com/icloud-photos-downloader/icloud_photos_downloader/issues/741)

Expand Down
366 changes: 183 additions & 183 deletions CONTRIBUTING.md

Large diffs are not rendered by default.

100 changes: 50 additions & 50 deletions EXPERIMENTAL.md
Original file line number Diff line number Diff line change
@@ -1,50 +1,50 @@
# Experimental Mode

Goal is to try new things and get feedback from users without breaking existing behavior.

Anything in this section can change without backward compatibity or even completely removed.

DANGER ZONE: Code may not work as expected.

## CLI format

Goal: reduce user confusion and maintanence burden by restructuring CLI interface for better matching use cases and related options

### New Structure

Ideas:
- Each use case is matched to command
- Customizations are available as options

Use Cases:
- Maintain local copy/backup of iCloud: **COPY** command
- Use iCloud as a transfer meduim to local storage (and clean iCloud afterwards): **MOVE** command

Othrogonal Needs:
- Scheduled sync: **WATCH** command
- management of persistent credentials: **AUTH** command
- monitoring/notification/alerting: TBD


### How to Use

Legacy command (compatible with prior versions):

`docker run -it --rm icloudpd:icloudpd icloudpd --help`

`docker run -it --rm icloudpd:icloudpd icloud --help`

`icloudpd-1.17.0-windows-amd64 --help`

Help:

`docker run -it --rm icloudpd:icloudpd`

`icloudpd-ex-1.17.0-windows-amd64 --help`

Example:

`docker run -it --rm icloudpd:icloudpd copy [email protected] /path/to/{album}/{date_created:%Y/%Y-%m}`

`icloudpd-ex-1.17.0-windows-amd64 copy [email protected] /path/to/{album}/{date_created:%Y/%Y-%m}`

# Experimental Mode

Goal is to try new things and get feedback from users without breaking existing behavior.

Anything in this section can change without backward compatibity or even completely removed.

DANGER ZONE: Code may not work as expected.

## CLI format

Goal: reduce user confusion and maintanence burden by restructuring CLI interface for better matching use cases and related options

### New Structure

Ideas:
- Each use case is matched to command
- Customizations are available as options

Use Cases:
- Maintain local copy/backup of iCloud: **COPY** command
- Use iCloud as a transfer meduim to local storage (and clean iCloud afterwards): **MOVE** command

Othrogonal Needs:
- Scheduled sync: **WATCH** command
- management of persistent credentials: **AUTH** command
- monitoring/notification/alerting: TBD


### How to Use

Legacy command (compatible with prior versions):

`docker run -it --rm icloudpd:icloudpd icloudpd --help`

`docker run -it --rm icloudpd:icloudpd icloud --help`

`icloudpd-1.17.1-windows-amd64 --help`

Help:

`docker run -it --rm icloudpd:icloudpd`

`icloudpd-ex-1.17.1-windows-amd64 --help`

Example:

`docker run -it --rm icloudpd:icloudpd copy [email protected] /path/to/{album}/{date_created:%Y/%Y-%m}`

`icloudpd-ex-1.17.1-windows-amd64 copy [email protected] /path/to/{album}/{date_created:%Y/%Y-%m}`

146 changes: 73 additions & 73 deletions FAQ.md
Original file line number Diff line number Diff line change
@@ -1,73 +1,73 @@
# Nuances and Known Issues

## iCloud Authentication

### MFA

If your Apple account has two-factor authentication (multi-factor authentication, MFA) enabled,
you will be prompted for a code when you run the script. Two-factor authentication will expire after an interval set by Apple,
at which point you will have to re-authenticate. This interval is currently two months. Apple requires MFA for all new accounts.

You can receive an email notification when two-factor authentication expires by passing the
`--smtp-username` and `--smtp-password` options. Emails will be sent to `--smtp-username` by default,
or you can send to a different email address with `--notification-email`.

If you want to send notification emails using your Gmail account, and you have enabled two-factor authentication, you will need to generate an App Password at <https://myaccount.google.com/apppasswords>

### FIDO

Authentication to iCloud with hardware keys (FIDO) is not supported.

### ADP

Advanced Data Protection (ADP) for iCloud accounts is not supported because iCloudPD simulates web access, which is disabled with ADP.

### System Keyring

You can store your password in the system keyring using the `icloud` command-line tool:

``` plain
$ icloud --username [email protected]
ICloud Password for [email protected]:
Save password in keyring? (y/N)
```

If you have stored a password in the keyring, you will not be required to provide a password
when running the script.

If you would like to delete a password stored in your system keyring,
you can clear a stored password using the `--delete-from-keyring` command-line option:

``` sh
icloud --username [email protected] --delete-from-keyring
```

## Error on the First Run

When you run the script for the first time, you might see an error message like this:

``` plain
Bad Request (400)
```

This error often happens because your account hasn't used the iCloud API before, so Apple's servers need to prepare some information about your photos. This process can take around 5-10 minutes, so please wait a few minutes and try again.

If you are still seeing this message after 30 minutes, then please [open an issue on GitHub](https://github.com/icloud-photos-downloader/icloud_photos_downloader/issues/new) and post the script output.

## Access from Mainland China

Access to iCloud.com is blocked from mainland China. `icloudpd` can be used with `--domain cn` parameter to support downloading iCloud phtotos from mainland China, however, people reported mixed results with that parameter.

## MacOS binary

`icloudpd` is available as Intel 64bit binary for MacOS, but works on ARM macs too (M1, M2).

Here are the steps to make it working:
- download binary from Github [Releases](https://github.com/icloud-photos-downloader/icloud_photos_downloader/releases) into desired local folder
- add executable flag by running `chmod +x icloudpd-1.17.0-macos-amd64`
- start it from the terminal: `icloudpd-1.17.0-macos-amd64`
- Apple will tell you that it cannot check for malicous software and refuse to run the app; click "Ok"
- Open "System Settings"/"Privacy & Security" and find `icloudpd-1.17.0-macos-amd64` as blocked app; Click "Allow"
- Start `icloudpd-1.17.0-macos-amd64` from the terminal again
- Apple will show another warning; click "Open"
- After that you can run `icloudpd-1.17.0-macos-amd64 --help` or any other supported command/option
# Nuances and Known Issues

## iCloud Authentication

### MFA

If your Apple account has two-factor authentication (multi-factor authentication, MFA) enabled,
you will be prompted for a code when you run the script. Two-factor authentication will expire after an interval set by Apple,
at which point you will have to re-authenticate. This interval is currently two months. Apple requires MFA for all new accounts.

You can receive an email notification when two-factor authentication expires by passing the
`--smtp-username` and `--smtp-password` options. Emails will be sent to `--smtp-username` by default,
or you can send to a different email address with `--notification-email`.

If you want to send notification emails using your Gmail account, and you have enabled two-factor authentication, you will need to generate an App Password at <https://myaccount.google.com/apppasswords>

### FIDO

Authentication to iCloud with hardware keys (FIDO) is not supported.

### ADP

Advanced Data Protection (ADP) for iCloud accounts is not supported because iCloudPD simulates web access, which is disabled with ADP.

### System Keyring

You can store your password in the system keyring using the `icloud` command-line tool:

``` plain
$ icloud --username [email protected]
ICloud Password for [email protected]:
Save password in keyring? (y/N)
```

If you have stored a password in the keyring, you will not be required to provide a password
when running the script.

If you would like to delete a password stored in your system keyring,
you can clear a stored password using the `--delete-from-keyring` command-line option:

``` sh
icloud --username [email protected] --delete-from-keyring
```

## Error on the First Run

When you run the script for the first time, you might see an error message like this:

``` plain
Bad Request (400)
```

This error often happens because your account hasn't used the iCloud API before, so Apple's servers need to prepare some information about your photos. This process can take around 5-10 minutes, so please wait a few minutes and try again.

If you are still seeing this message after 30 minutes, then please [open an issue on GitHub](https://github.com/icloud-photos-downloader/icloud_photos_downloader/issues/new) and post the script output.

## Access from Mainland China

Access to iCloud.com is blocked from mainland China. `icloudpd` can be used with `--domain cn` parameter to support downloading iCloud phtotos from mainland China, however, people reported mixed results with that parameter.

## MacOS binary

`icloudpd` is available as Intel 64bit binary for MacOS, but works on ARM macs too (M1, M2).

Here are the steps to make it working:
- download binary from Github [Releases](https://github.com/icloud-photos-downloader/icloud_photos_downloader/releases) into desired local folder
- add executable flag by running `chmod +x icloudpd-1.17.1-macos-amd64`
- start it from the terminal: `icloudpd-1.17.1-macos-amd64`
- Apple will tell you that it cannot check for malicous software and refuse to run the app; click "Ok"
- Open "System Settings"/"Privacy & Security" and find `icloudpd-1.17.1-macos-amd64` as blocked app; Click "Allow"
- Start `icloudpd-1.17.1-macos-amd64` from the terminal again
- Apple will show another warning; click "Open"
- After that you can run `icloudpd-1.17.1-macos-amd64 --help` or any other supported command/option
84 changes: 42 additions & 42 deletions binary_dist/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,42 +1,42 @@
[build-system]
requires = [
"setuptools>=68.0.0,<69",
"wheel>=0.40.0,<0.41",
]
build-backend = "setuptools.build_meta"

[project]
version="1.17.0"
name = "icloudpd"
description = "icloudpd is a command-line tool to download photos and videos from iCloud."
readme = "README_PYPI.md"
requires-python = ">=2"
keywords = ["icloud", "photo"]
license = {file="LICENSE.md"}
authors=[
{name = "The iCloud Photo Downloader Authors"}
]
classifiers = [
"Intended Audience :: End Users/Desktop",
"Operating System :: OS Independent",
"License :: OSI Approved :: MIT License",
]
# https://pypi.org/pypi?%3Aaction=list_classifiers

[project.optional-dependencies]
dev = [
"wheel>=0.40.0,<0.41"
]

[project.urls]
Homepage="https://github.com/icloud-photos-downloader/icloud_photos_downloader"

[tool.setuptools.package-data]
"*" = ["icloud*"]

[tool.distutils.bdist_wheel]
universal = true

[project.scripts]
icloudpd = "icloudpd:__main__"
icloud = "icloud:__main__"
[build-system]
requires = [
"setuptools>=68.0.0,<69",
"wheel>=0.40.0,<0.41",
]
build-backend = "setuptools.build_meta"

[project]
version="1.17.1"
name = "icloudpd"
description = "icloudpd is a command-line tool to download photos and videos from iCloud."
readme = "README_PYPI.md"
requires-python = ">=2"
keywords = ["icloud", "photo"]
license = {file="LICENSE.md"}
authors=[
{name = "The iCloud Photo Downloader Authors"}
]
classifiers = [
"Intended Audience :: End Users/Desktop",
"Operating System :: OS Independent",
"License :: OSI Approved :: MIT License",
]
# https://pypi.org/pypi?%3Aaction=list_classifiers

[project.optional-dependencies]
dev = [
"wheel>=0.40.0,<0.41"
]

[project.urls]
Homepage="https://github.com/icloud-photos-downloader/icloud_photos_downloader"

[tool.setuptools.package-data]
"*" = ["icloud*"]

[tool.distutils.bdist_wheel]
universal = true

[project.scripts]
icloudpd = "icloudpd:__main__"
icloud = "icloud:__main__"
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ requires = [
build-backend = "setuptools.build_meta"

[project]
version="1.17.0"
version="1.17.1"
name = "icloudpd"
description = "icloudpd is a command-line tool to download photos and videos from iCloud."
readme = "README_PYPI.md"
Expand Down
28 changes: 14 additions & 14 deletions scripts/publish_pypi
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
#!/bin/bash
set -euo pipefail

# dev script
# expecting dist/binary_dist to be set
# required param registry_url
#
# prereq
# disable auth on pypi server
#
# cleint use: pip install --index http://192.168.1.20:4880 --trusted-host 192.168.1.20 icloudpd

# linux
twine upload --repository-url $1 --non-interactive -u bogus -p bogus dist/icloudpd-1.17.0-py2.py3-none-manylinux*.whl dist/icloudpd-1.17.0-py2.py3-none-macos*.whl dist/icloudpd-1.17.0-py2.py3-none-win*.whl dist/icloudpd-1.17.0-py3-none-any.whl
#!/bin/bash
set -euo pipefail

# dev script
# expecting dist/binary_dist to be set
# required param registry_url
#
# prereq
# disable auth on pypi server
#
# cleint use: pip install --index http://192.168.1.20:4880 --trusted-host 192.168.1.20 icloudpd

# linux
twine upload --repository-url $1 --non-interactive -u bogus -p bogus dist/icloudpd-1.17.1-py2.py3-none-manylinux*.whl dist/icloudpd-1.17.1-py2.py3-none-macos*.whl dist/icloudpd-1.17.1-py2.py3-none-win*.whl dist/icloudpd-1.17.1-py3-none-any.whl
Loading

0 comments on commit 5594317

Please sign in to comment.