Skip to content

Conversation

@armanexplorer
Copy link
Contributor

The main reason for this PR is the final part of the FileSystemStorage._save() method in the Django library that leads to generating unnormalized paths:

...

# Store filenames with forward slashes, even on Windows.
return str(name).replace('\\', '/')

So, we should care for the normalized paths generated by namer (using os.path.normpath()) against the unnormalized paths generated by Django Storage. Hence, this leads to a fault when the OS doesn't use forward slashes for the path formatting, like Windows.

@Tekpakma
Copy link

Tekpakma commented Dec 4, 2022

Good change IMO, fixes annoying logger message on Windows.

@vstoykov vstoykov merged commit 5cdb4c2 into matthewwithanm:develop Apr 5, 2023
@vstoykov
Copy link
Collaborator

vstoykov commented Apr 5, 2023

Thanks for the contribution

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants