TheLastGimbus / GooglePhotosTakeoutHelper

Script that organizes the Google Takeout archive into one big chronological folder
https://aur.archlinux.org/packages/gpth-bin
Apache License 2.0
3.88k stars 191 forks source link

Nice message instead of exception when no photos #134

Closed preppietechie closed 1 year ago

preppietechie commented 1 year ago

I've got the contents of my google photos takeout zip files extracted to c:\user\username\desktop\photos-decompress\Takeout\GooglePhotos\ (so it's a big folder full of dated subfolders which, in turn contain the images and json files).

Running v3.0, It appears that it can't find any contents of the specified folder, and I get the following error:

C:\Users\Username\Downloads> gpth-v3.0.0-Windows.exe -i C:\users\Username\Desktop\photos-decompress\Takeout\GooglePhotos\ -o C:\users\Username\Desktop\photos-decompress\cu\ WARNING: Script will move files from input to output - not copy

Okay, running... searching for everything in input folder... Found 0 photos/videos in input folder Unhandled exception: Unsupported operation: Infinity or NaN toInt

0 FillingBar._render (package:console_bars/src/filling_bar.dart)

1 new FillingBar (package:console_bars/src/filling_bar.dart:73)

2 main (file:///d:/a/googlephotostakeouthelper/googlephotostakeouthelper/bin/gpth.dart:220)

C:\Users\username\Downloads>
preppietechie commented 1 year ago

It also does the same thing if I specify c:\users\username\Desktop\photos-decompress\Takeout\

TheLastGimbus commented 1 year ago

huh, weird... do you have "year folders" in your takeout? folders named like "Photos from 2016" ? or just albums

preppietechie commented 1 year ago

just the albums... folders like:

C:\Users\username\Desktop\photos-decompress\Takeout\Google Photos\1-27-12\ and C:\Users\username\Desktop\photos-decompress\Takeout\Google Photos\2013 San Francisco\

with photos and json files inside them.

TheLastGimbus commented 1 year ago

Okay then - new script takes all photos only from year folders, and looks up at albums only to link the information about them (which it currently does nothing with, see #135)

If you can, just take the new export from google and select only "photos from ..." folders

Otherwise, best option is to use old python version

Is there some particular reason you have this like that? I may change the behavior of current code if there is...

preppietechie commented 1 year ago

I think it’s a throwback to the old Picasso days maybe? Honestly it’s been this way so long I’m unsure of exactly when it started. I wouldn’t make any changes that limit 3.x for my edge case. I’ll chug along with 2.3.1. You’ve written an amazing tool! Thank you!

On Mon, Dec 19, 2022 at 6:06 PM Mateusz Soszyński @.***> wrote:

Okay then - new script takes all photos only from year folders, and looks up at albums only to link the information about them (which it currently does nothing with, see #135 https://github.com/TheLastGimbus/GooglePhotosTakeoutHelper/discussions/135 )

If you can, just take the new export from google and select only "photos from ..." folders

Otherwise, best option is to use old python version

Is there some particular reason you have this like that? I may change the behavior of current code if there is...

— Reply to this email directly, view it on GitHub https://github.com/TheLastGimbus/GooglePhotosTakeoutHelper/issues/134#issuecomment-1358534979, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQJAKUF2XKQJEQEV2YVIWMDWODS6DANCNFSM6AAAAAATCFMSKY . You are receiving this because you authored the thread.Message ID: @.***>

TheLastGimbus commented 1 year ago

Okay so... when you took your takeout, you selected all the folders, and that's just the way yours is?

KM192 commented 1 year ago

I have the same issue. My case is that I would like to take from Google only photos from albums, while they are well organized by me. I do not care or even do not want to take all pictures from whole years. is there a chance that program would take pictures from all albums and would re-create album structure in the output folder ?

TheLastGimbus commented 1 year ago

@KM192 Yeah, i think this will be main "album impementation". See #135 discussion for that

Looks like I will have to change behaviour of photo-finding... created #140 for that

llliax commented 1 year ago

For a long time I could not understand why all my photos did not want to be converted. Please add in bold to the instructions that the photos should be at the root of the year folder. Then the transfer happens. The transfer is lightning fast! Thank you for your work!

TheLastGimbus commented 1 year ago

For now, gpth just prints a nice message. I won't implement "Albums only" mode because it would complicate stuff very much.

@llliax there is now interactive mode which exports the zips for you, leaving no place for user error (other than wrongly selecting zips) - hope this fixes your problem :grin: !