boredazfcuk / docker-icloudpd

An Alpine Linux container for the iCloud Photos Downloader command line utility
1.79k stars 168 forks source link

Exit code 2 #73

Closed bijca closed 3 years ago

bijca commented 3 years ago

Hi, since yesterday I'm getting this error in Telegram regarding iCloudPD:

🚨 boredazfcuk/iCloudPD iCloudPD failed to download new files - for Apple ID: ***@gmail.com Exit code 2

After stopping and restarting the container it does sync:

ℹ️ boredazfcuk/iCloudPD New files detected for Apple ID ****@gmail.com: 10 Last 10 file names:

I really have no idea where to look and I couldn't find anything hereeither. Anyone care to point me in the right direction?

Thanks in advance for your help!

boredazfcuk commented 3 years ago

Can you update to the latest version which I've just pushed to Dockerhub, please?

The error you're getting appears twice in my script, so I can't tell whereabouts it's failing. The new script will tell me if it's during the check, or during the actual download.

Also, can you see the health status of the container? It may say what the error is there... Whether it's a file check error, download error or 2FA/Password related.

Thanks.

bijca commented 3 years ago

Sorry for the late response, I had to stay in the hospital for a while.

Can you update to the latest version which I've just pushed to Dockerhub, please?

I have updated to the latest version and now the error does not return.

Also, can you see the health status of the container?

Maybe a little stupid, but how do I do that?

Cheers!

boredazfcuk commented 3 years ago

Sorry for the late response, I had to stay in the hospital for a while.

Hope you're OK and it wasn't the dreaded COVID-19!

I have updated to the latest version and now the error does not return.

Oh, that's strange. I only changed message that gets logged. I use Telegram for notifications too though, and haven't noticed any issues recently. So it's not like Telegram changed the API or something. Maybe it was just an outage on Telegram's network in your part of the world.

Maybe a little stupid, but how do I do that?

You can view the status of the container with docker inspect like:

docker inspect --format='{{json .State.Health}}' <container_name>

e.g.

docker inspect --format='{{json .State.Health}}' icloudpd_1
bijca commented 3 years ago

Hope you're OK and it wasn't the dreaded COVID-19!

No, not COVID.It is a pulmonary embolism, also not really a reason for celebration ;-)

docker inspect --format='{{json .State.Health}}' icloudpd_1

{{"Status":"healthy","FailingStreak":0,"Log":[{"Start":"2021-07-11T17:03:46.174217151+02:00","End":"2021-07-11T17:03:46.245406284+02:00","ExitCode":0,"Output":"iCloud Photos Downloader successful and 2FA cookie valid for 32 day(s)\n"},{"Start":"2021-07-11T17:04:46.264516894+02:00","End":"2021-07-11T17:04:46.339799591+02:00","ExitCode":0,"Output":"iCloud Photos Downloader successful and 2FA cookie valid for 32 day(s)\n"},{"Start":"2021-07-11T17:05:46.365114466+02:00","End":"2021-07-11T17:05:46.437691027+02:00","ExitCode":0,"Output":"iCloud Photos Downloader successful and 2FA cookie valid for 32 day(s)\n"},{"Start":"2021-07-11T17:06:46.455059421+02:00","End":"2021-07-11T17:06:46.52755337+02:00","ExitCode":0,"Output":"iCloud Photos Downloader successful and 2FA cookie valid for 32 day(s)\n"},{"Start":"2021-07-11T17:07:46.544319032+02:00","End":"2021-07-11T17:07:46.615155178+02:00","ExitCode":0,"Output":"iCloud Photos Downloader successful and 2FA cookie valid for 32 day(s)\n"}]}

boredazfcuk commented 3 years ago

It is a pulmonary embolism, also not really a reason for celebration

Glad you're lucky enough to tell the story! Sounds like you need some rest to led the medication do its thing.

"ExitCode":0

This is good, this means it's healthy. Plus I can see you have 32 days before you need to renew your 2FA cookie.