-
-
Notifications
You must be signed in to change notification settings - Fork 867
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
S3 credentials in links missing for private buckets after upgrade to Django 5.1 #1443
Comments
I've also run in this issue 😞 |
Upon further inspection it looks like the newer version of django is overwriting parts of the storage backend. I was debugging a bit and found that the variable stored here: https://github.com/django/django/blob/main/django/db/models/fields/files.py#L25 This |
Hi @kylepollina, You might of missed the django-storages config change https://django-storages.readthedocs.io/en/latest/backends/amazon-S3.html#configuration-settings This changed for django 4.2 |
@rory-ferguson Thanks for the investigation, we didn't use the new |
@rory-ferguson Thank you! I updated my configurations and this fixed my issue. |
Seems to work here, too. Should this be documented somewhere? 🤔 |
@GitRon it is documented on the bottom of the Django 5.1 release notes. https://docs.djangoproject.com/en/5.1/releases/5.1/
|
@kylepollina You are right! Still don't get it, why Django works with the old settings 😆 Well, maybe really not a storages-problem 🤷♂️ On the other side, explicit is better than implicit. I'll leave it to the maintainers to decide this. Thanks for the support everyone ❤️ |
Hi @jschneier!
I found an issue with Django 5.1. After the upgrade (using django-storages 1.14.4), all GET-parameter credentials for private S3 buckets are not being added to the links in my templates anymore. This means that I don't have access to the files.
I have no idea and since I have little knowledge on how this amazing package works, I can't really contribute any suggestions. 😔 I just verified that it's really Django 5.1.
Here's my setup, it might help in reconstructing the case.
Thanks so much for looking into this!
Ronny
PS: It seens unrelated to #1437 since there, Django 4.2 was used.
The text was updated successfully, but these errors were encountered: