-
Notifications
You must be signed in to change notification settings - Fork 73
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
When using s3 boto storage, path gets prepended to the filename twice #50
Comments
Used an alteration of the above to fix this for the normal storage method. Add to settings.py STATICSITEMAPS_STORAGE = 'myproject.sitemaps.SitemapStorage' Add to myproject/sitemaps.py from django.core.files.storage import FileSystemStorage
class SitemapStorage(FileSystemStorage):
def __init__(self, *args, **kwargs):
super(SitemapStorage, self).__init__(*args, **kwargs)
self.location = '' As @lsemel says, this fixes the duplication of a custom SITEMAP_ROOT_DIR |
@digitaltommy Can you make a pull request out of it? It would be appreciated. Thx |
@xaralis sorry just seen this comment - do these pull requests need doing still? |
It's because
and S3 storage prepends
Before fixing it, we should find out the original intent of |
@puzzlet Correct. I've reviewed the code and don't see any specific reason why this line ( It's probably some old thing that noone noticed. It should be safe to remove. |
still not fixed? |
The value of SITEMAP_ROOT_DIR gets prepended to the filename twice. I had do use a custom storage to avoid this happening:
The text was updated successfully, but these errors were encountered: