Giter Club home page Giter Club logo

Comments (8)

mtalcott avatar mtalcott commented on May 22, 2024 2

storageFilename is set by a separate subtask that downloads the actual thumbnail images for performance purposes. Right now, if one of those subtasks fails it'll still proceed, but then run into this error, possibly others too, when calculating duplicates.

Two options I see to address:

  1. Skip invalid media items during processing, logging a warning.
  2. Fail the main task if a subtask fails, prompt the user to start again.

I'm leaning toward Option 2 for now, and will make that change soon. My reasoning is it's also what I'm doing when daily quota is exceeded, because if 1 failed it's likely that others may have failed as well, and the application is already optimized to skip over media items where the thumbnail has already been downloaded.

This will also benefit the project as I can get a better sense of why the subtasks are failing and not setting storageFilename, and better address the root issue.

from google-photos-deduper.

mtalcott avatar mtalcott commented on May 22, 2024 1

@olsw I plan to find some time over the holidays, so by end of year.

from google-photos-deduper.

bighippo999 avatar bighippo999 commented on May 22, 2024

So GPT suggest this:

def _get_storage_path(self, media_item) -> str:
    if "storageFilename" in media_item:
        return self.image_store.get_storage_path(media_item["storageFilename"])
    else:
        self.logger.error(f"'storageFilename' not found in media_item: {media_item}")
        return None  # Or handle this case differently, perhaps raising a custom exception

It worked, and now have a screen full of duplicates :)
Going to leave this open though, as it's probably better to fix for all.

from google-photos-deduper.

c0sm0t0pian avatar c0sm0t0pian commented on May 22, 2024

Getting the same error (KeyError: 'storageFilename') basically. I can see that some media_items have no storageFilename in their dictionary. The solution suggested by @bighippo999 does not work for me since returning None throws an error later in the game. I think that the root cause needs to be fixed where the media_items get populated and there must be a reason why there is no storageFilename saved for some. But I haven't figured out where that happens, nor why it does (not) happen yet... any help is appreciated...

from google-photos-deduper.

olsw avatar olsw commented on May 22, 2024

@mtalcott any indication when this will be released? Many thanks

from google-photos-deduper.

minermartijn avatar minermartijn commented on May 22, 2024

I think im having the same issues, and im hoping you can fix them soon.

Edit:
Welllll, something that worked for me was using Google Chrome instead of FireFox!
I installed the extention before starting program aswell. Hopefully this will help someone else aswell.

Thanks alot @mtalcott this app is awesome, got to remove so many dupe's
The only downside is that i need to shutdown my own Nginx container to get this running. But still awesome!!!!

from google-photos-deduper.

mtalcott avatar mtalcott commented on May 22, 2024

I've merged #32 which should help identify the root issue(s) at play here. Please pull the latest from main branch to get the update.

A new log/celery_worker.log will be created, I'd appreciate it if anyone is willing to share a relevant stacktrace from theirs here.

from google-photos-deduper.

Related Issues (18)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.