Changes between Initial Version and Version 2 of Ticket #36384


Ignore:
Timestamp:
May 15, 2025, 10:21:17 AM (4 months ago)
Author:
Tim Graham
Comment:

The quote code snippet is checking whether the ImageField has height/width fields specified, so that's not the code that will raise an exception. The report certainly seems plausible, even if it's unclear how the situation could be improved. It might be the S3 storage backend rather than Django that should be resilient to network failure.

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #36384

    • Property Resolutionworksforme
    • Property Status newclosed
    • Property Easy pickings unset
  • Ticket #36384 – Description

    initial v2  
    55For example with S3 issue it might raise:
    66
    7 ```
    8 ClientError: An error occurred (403) when calling the HeadObject operation: Forbidden
    9 ```
     7`ClientError: An error occurred (403) when calling the HeadObject operation: Forbidden`
    108
    119even when I simply want to get the object without the width and height, like here:
    1210
    13 ```
    14 UserAvatar.objects.get(user=user).only('id')
    15 ```
     11`UserAvatar.objects.get(user=user).only('id')`
    1612
    1713This is in my opinion an unexpected consequence of adding the height_field and width_field to an ImageField.
Back to Top