I can upload an attachment using various methods (copy-pasting or upload command). The uploaded files appear on the file system, but are not accessible to the web server (if I try to open the path, I get 404 not found).
Any idea what I’m doing wrong?
I’m running sb on an OSX device, in case it makes a difference.
Do you see any other error when checking the browser console?
I just tried from my phone copy and pasting an image from the internet in my instance and it worked as expected.
Are you using sync or online mode? I’ve seen the occasional caching issue (somehow the client caches the 404). Could you try the other mode and see if that changes anything? Do you see the file on disk?
There is no output on the browser console when I try to open the file directly, possibly indicating a browser cache issue, since no hits are seen on the server side (or at least not logged).
I do see the file on disk, so the upload works.
Edit: I tried refreshing the page with force-refresh (cmd+shift+r on mac), which resolved it. So the first time the browser tried to load the image, it wasn’t available, and the browser’s cache returned the 404 subsequently.
Hum ho, I should have figured this out myself. Maybe suggesting force-refresh as a fix to the issue could be added to the Attachments documentation page. I did try restarting the service and forcing reindexing on the server side, but didn’t think of browser cache.