Opened 12 years ago
Closed 12 years ago
#11078 closed defect (duplicate)
Images not available after upload
Reported by: | Ryan J Ollos | Owned by: | Michael Renzmann |
---|---|---|---|
Priority: | normal | Component: | TracHacks |
Severity: | normal | Keywords: | |
Cc: | Steffen Hoffmann, Ryan J Ollos | Trac Release: |
Description
Images are often not available after upload, such as attachment/ticket/11077/Screen%20shot%202013-05-14%20at%202.28.12%20AM.png in ticket #11077. I've seen this on several occasions, but I've not figured out why some images have issues and others seem to be fine.
The long term solution is to upgrade the site, but I'm hoping to determine a workaround for the interm.
The file looks to be intact on the server,
rjollos@hacks:~$ ls -l /srv/trac-hacks.org/trac/attachments/ticket/11077/Screen%20shot%202013-05-14%20at%202.28.12%20AM.png -rwxr-xr-x 1 www-data www-data 169703 May 13 18:29 /srv/trac-hacks.org/trac/attachments/ticket/11077/Screen%20shot%202013-05-14%20at%202.28.12%20AM.png
so I grabbed the file with SCP and I can open it on my workstation. I renamed the file to have a shorter filename with no whitespaces, re-uploaded it and now it displays fine (attachment/ticket/11077/ScreenShot.png).
rjollos@hacks:~$ ls -l /srv/trac-hacks.org/trac/attachments/ticket/11077/ total 344 -rwxr-xr-x 1 www-data www-data 169703 May 13 18:29 Screen%20shot%202013-05-14%20at%202.28.12%20AM.png -rwxr-xr-x 1 www-data www-data 169703 May 13 23:24 ScreenShot.png
Attachments (0)
Change History (3)
comment:1 follow-up: 2 Changed 12 years ago by
comment:2 follow-up: 3 Changed 12 years ago by
Replying to rjollos:
From the instances I've seen so far, it seems that this may be caused by spaces in the filenames. I never include spaces in the attachments I upload and can't recall experiencing this issue myself.
I support that conclusion. Obviously Trac care has been going at great length for fixing issues caused by 'insane' file naming in 0.11/0.12, because I see no similar issues in my instances of Trac (all 0.11 and above), but as we know Trac-1.0 even resorts to using hashed file names now. So this is something to watch out on upgrade, but these 'lost' files should just re-appear, if all goes well after the upgrade to 1.0
, right?
comment:3 Changed 12 years ago by
Resolution: | → duplicate |
---|---|
Status: | new → closed |
Replying to hasienda:
So this is something to watch out on upgrade, but these 'lost' files should just re-appear, if all goes well after the upgrade to
1.0
, right?
Yeah, that makes sense. I'll keep my eye out for attachment issues when I review the RSS feed each day, and just advise users to remove the whitespace and try the upload again.
Closing as a duplicate of #10193.
From the instances I've seen so far, it seems that this may be caused by spaces in the filenames. I never include spaces in the attachments I upload and can't recall experiencing this issue myself.