vale46n1 / immich_duplicate_finder

A Comprehensive Solution for Identifying and Managing Duplicate Photos in Immich

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Video in immich

Sn0wAlice opened this issue · comments

Seems to crash on video

           try:
                if response.text:
                    assets = response.json()
                    st.success('Assets fetched successfully!')
                    return assets
                else:
                    st.error('Received an empty response.')
                    return None
            except requests.exceptions.JSONDecodeError as e:
                st.error('Failed to decode JSON from the response.')
                st.error(f'Response content: {response.text}')
                return None

add an asset filter assets = [asset for asset in assets if asset.get("type") == "IMAGE"] seems to patch the problem

           try:
                if response.text:
                    assets = response.json()
                    assets = [asset for asset in assets if asset.get("type") == "IMAGE"]
                    st.success('Assets fetched successfully!')
                    return assets
                else:
                    st.error('Received an empty response.')
                    return None
            except requests.exceptions.JSONDecodeError as e:
                st.error('Failed to decode JSON from the response.')
                st.error(f'Response content: {response.text}')
                return None

Thank you for your feedback! I'm planning to incorporate your suggestion into the project. Additionally, I'm exploring a feature to detect duplicate videos, which I'll be working on in the coming days. To enhance user experience, I'm also considering revising the app using React. Stay tuned for updates!

gl for the react update ^^