I’m not sure if this can be called a bug, but it is an unexpected behavior:
Steps to reproduce:
- Add a new file extension like
- Attach a file with that extension to a post
- Remove the file extension from
- Rebake all posts using
Rebaking of all posts should work, even though the previously attached file extension isn’t allowed anymore.
Rebaking of posts fails for all posts that have attachments which aren’t allowed anymore. They are stuck in the sidekiq retry queue. The error message is:
Job exception: Wrapped ActiveRecord::RecordInvalid: Validation failed: Original filename Sorry, the file you are trying to upload is not authorized (authorized extensions: jpg, jpeg, png, gif).
This error happens only with images. It doesn’t seem to happen with other file types.
max_image_size_kb also results in errors:
Job exception: Wrapped ActiveRecord::RecordInvalid: Validation failed: Filesize Sorry, the image you are trying to upload is too big (maximum size is 3072KB), please resize it and try again.