mirror of
https://github.com/photoprism/photoprism.git
synced 2026-03-02 22:57:18 -05:00
Segfault at import #36
Labels
No labels
ai
android
api
auth
awesome
bug
bug
ci
cli
config
database
declined
deprecated
docker
docs 📚
documents
duplicate
easy
enhancement
enhancement
enhancement
epic
faces
feedback wanted
frontend
hacktoberfest
help wanted
idea
in-progress
incomplete
index
invalid
ios
labels
live
live
low-priority
macos
member-feature
metadata
mobile
nas
needs-analysis
no-coding-required
no-coding-required
observability
performance
places
please-test
plus-feature
priority
pro-feature
question
raspberry-pi
raw
released
released
released
research
resolved
security
sharing
tested
tests
third-party-issue
thumbnails
upgrade
upstream-issue
ux
vector
video
waiting
won't fix
won't fix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/photoprism#36
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @gmelchett on GitHub (Oct 16, 2018).
Originally assigned to: @lastzero on GitHub.
A fresh docker install (commit
6844c5f36f) crashedwhen importing about 3000 photos.
@lastzero commented on GitHub (Oct 16, 2018):
Looks like an issue with color indexing, see #7
Guess when github.com/RobCherry/vibrant is gone, the issue will be gone...
@gmelchett commented on GitHub (Oct 17, 2018):
Thanks for having a look! I tried to import only the photo that caused the segfault in a new docker instance, and the crash occurred again.
I don't know if it is of any help, but here is a link to the photo that triggers this bug http://lithops.se/IMG_20170425_062158425.jpg (Original, ~10 MB large)
@u5surf commented on GitHub (Oct 18, 2018):
@lastzero , @gmelchett
I tested @gmelchett 's image on vibrant library.
And I figured out the following issue of go image library that some special jpg cannot decode.
https://github.com/golang/go/issues/10447
reproducing
wget http://lithops.se/IMG_20170425_062158425.jpg -O sample.jpgand following code runs, then it can be output
invalid JPEG format: short Huffman dataresult:
But also I think it's better to be handling those errors properly.
@lastzero commented on GitHub (Oct 18, 2018):
Would https://github.com/disintegration/imaging also be affected? This is what we're using for resizing etc...
@u5surf commented on GitHub (Oct 18, 2018):
I checked github.com/disintegration/imaging is affected because
image.Decodeis called byimaging.Open(m.filename, imaging.AutoOrientation(true))in your code.i.e.
github.com/photoprism/photoprism@6844c5f36f/internal/photoprism/thumbnails.go (L103)but it maynot cause segfalt if you care failed safe the error that is catches next statements.
@lastzero commented on GitHub (Oct 18, 2018):
So ultimately that means we need to replace "image/jpeg" or we can not import certain images as the issue was closed by the golang team. Any opinions / alternatives?
@gmelchett commented on GitHub (Oct 18, 2018):
Looking at golang/go/issues/10447 it looks like the cause could be that the image is truncated, and indeed my photo is truncated. In Firefox (62), the bottom lines are white, while in Gimp (2.10) only the down right corner isn't correct.
The photos is taken by a Qualcomm based mobile phone with stock Android. (Moto X Force)
@lastzero commented on GitHub (Oct 20, 2018):
So ignoring it would be OK until we find a better solution?
@gmelchett commented on GitHub (Oct 20, 2018):
Yes, it would be OK. However, it would be nice it photoprism didn't crash upon such images. Ignoring them would be prefered, maybe copy/move these faulty images to a special folder with faulty images?
@lastzero commented on GitHub (Oct 21, 2018):
Of course it shouldn't crash later, but for now this is what we want. Fail fast. Otherwise, nobody would have complained and it might not have gotten any attention. Now we know there is a problem.
@lastzero commented on GitHub (Jan 20, 2020):
Think we can close this.