Could not find file in the store located at url s3

Hello,

I’ve got a strange error for few days in logs. I am on the very latest Discourse: 06e1af2b1d

I am using DigitalOcean Spaces S3.

This is sometimes happening per day but the image is exist on the space and appear on the website too.

Thanks for any response! :slight_smile:
Have a great day! :heart:

Message
Could not find file in the store located at url: //s3-url-sample000101.fra1.digitaloceanspaces.com/original/2X/d/db1d897feb561d9e58da9804ba59362cfe83cb4f.jpeg
This url is a sample (not gonna work)

Backtrace

/var/www/discourse/app/models/optimized_image.rb:76:in `block in create_for'

/var/www/discourse/app/models/optimized_image.rb:19:in `block in lock'

/var/www/discourse/lib/distributed_mutex.rb:33:in `block in synchronize'

/var/www/discourse/lib/distributed_mutex.rb:29:in `synchronize'

/var/www/discourse/lib/distributed_mutex.rb:29:in `synchronize'

/var/www/discourse/lib/distributed_mutex.rb:14:in `synchronize'

/var/www/discourse/app/models/optimized_image.rb:18:in `lock'

/var/www/discourse/app/models/optimized_image.rb:68:in `create_for'

/var/www/discourse/app/models/upload.rb:98:in `get_optimized_image'

/var/www/discourse/app/models/upload.rb:83:in `create_thumbnail!'

/var/www/discourse/lib/cooked_post_processor.rb:343:in `convert_to_link!'

/var/www/discourse/lib/cooked_post_processor.rb:723:in `block in post_process_images'

nokogiri-1.11.6-x86_64-linux/lib/nokogiri/xml/node_set.rb:239:in `block in each'

nokogiri-1.11.6-x86_64-linux/lib/nokogiri/xml/node_set.rb:238:in `upto'

nokogiri-1.11.6-x86_64-linux/lib/nokogiri/xml/node_set.rb:238:in `each'

/var/www/discourse/lib/cooked_post_processor.rb:722:in `post_process_images'

/var/www/discourse/lib/cooked_post_processor.rb:39:in `block in post_process'

/var/www/discourse/lib/distributed_mutex.rb:33:in `block in synchronize'

/var/www/discourse/lib/distributed_mutex.rb:29:in `synchronize'

/var/www/discourse/lib/distributed_mutex.rb:29:in `synchronize'

/var/www/discourse/lib/distributed_mutex.rb:14:in `synchronize'

/var/www/discourse/lib/cooked_post_processor.rb:35:in `post_process'

/var/www/discourse/app/jobs/regular/process_post.rb:26:in `block in execute'

/var/www/discourse/lib/distributed_mutex.rb:33:in `block in synchronize'

/var/www/discourse/lib/distributed_mutex.rb:29:in `synchronize'

/var/www/discourse/lib/distributed_mutex.rb:29:in `synchronize'

/var/www/discourse/lib/distributed_mutex.rb:14:in `synchronize'

/var/www/discourse/app/jobs/regular/process_post.rb:10:in `execute'

/var/www/discourse/app/jobs/base.rb:232:in `block (2 levels) in perform'

rails_multisite-3.0.0/lib/rails_multisite/connection_management.rb:80:in `with_connection'

/var/www/discourse/app/jobs/base.rb:221:in `block in perform'

/var/www/discourse/app/jobs/base.rb:217:in `each'

/var/www/discourse/app/jobs/base.rb:217:in `perform'

sidekiq-6.2.1/lib/sidekiq/processor.rb:196:in `execute_job'

sidekiq-6.2.1/lib/sidekiq/processor.rb:164:in `block (2 levels) in process'

sidekiq-6.2.1/lib/sidekiq/middleware/chain.rb:138:in `block in invoke'

/var/www/discourse/lib/sidekiq/pausable.rb:138:in `call'

sidekiq-6.2.1/lib/sidekiq/middleware/chain.rb:140:in `block in invoke'

sidekiq-6.2.1/lib/sidekiq/middleware/chain.rb:143:in `invoke'

sidekiq-6.2.1/lib/sidekiq/processor.rb:163:in `block in process'

sidekiq-6.2.1/lib/sidekiq/processor.rb:136:in `block (6 levels) in dispatch'

sidekiq-6.2.1/lib/sidekiq/job_retry.rb:112:in `local'

sidekiq-6.2.1/lib/sidekiq/processor.rb:135:in `block (5 levels) in dispatch'

sidekiq-6.2.1/lib/sidekiq.rb:38:in `block in <module:Sidekiq>'

sidekiq-6.2.1/lib/sidekiq/processor.rb:131:in `block (4 levels) in dispatch'

sidekiq-6.2.1/lib/sidekiq/processor.rb:257:in `stats'

sidekiq-6.2.1/lib/sidekiq/processor.rb:126:in `block (3 levels) in dispatch'

sidekiq-6.2.1/lib/sidekiq/job_logger.rb:13:in `call'

sidekiq-6.2.1/lib/sidekiq/processor.rb:125:in `block (2 levels) in dispatch'

sidekiq-6.2.1/lib/sidekiq/job_retry.rb:79:in `global'

sidekiq-6.2.1/lib/sidekiq/processor.rb:124:in `block in dispatch'

sidekiq-6.2.1/lib/sidekiq/logger.rb:11:in `with'

sidekiq-6.2.1/lib/sidekiq/job_logger.rb:33:in `prepare'

sidekiq-6.2.1/lib/sidekiq/processor.rb:123:in `dispatch'

sidekiq-6.2.1/lib/sidekiq/processor.rb:162:in `process'

sidekiq-6.2.1/lib/sidekiq/processor.rb:78:in `process_one'

sidekiq-6.2.1/lib/sidekiq/processor.rb:68:in `run'

sidekiq-6.2.1/lib/sidekiq/util.rb:43:in `watchdog'

sidekiq-6.2.1/lib/sidekiq/util.rb:52:in `block in safe_thread'

I think it’s happening when the system try to create the thumbnail from the image. Sometimes the thumbnail creation doesn’t work. If there is no empty line between the text and image it won’t create thumbnail sometimes. Same happening on multiple image upload. Hard to figure out because it is random. Sometimes work sometimes not. :confused:

When the thumbnail not created with rebuild html it create the missing thumbnail.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.