'ClientError at /saved_json/ An error occurred (403) when calling the HeadObject operation: Forbidden

I was trying to add images, json files to s3 bucket. It was going well about few months ago but I have opened it now and it shows an error on the line where the object of model is created.

Error named:

Exception Type: ClientError at /saved_json/ Exception Value: An error occurred (403) when calling the HeadObject operation: Forbidden

for image in images:
    photo = Photo.objects.create( //eror is here 
        email=data['email'],
        image=image,
    )


Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source