Skip to content
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

Fix a regression in determining when to collect static files. #610

Merged
merged 1 commit into from
Jan 15, 2017

Conversation

chipx86
Copy link
Contributor

@chipx86 chipx86 commented Dec 31, 2016

A commit made in 1.6.10 (ae6b3f8)
changed a storage lookup to use the prefixed_path variable instead of
the path variable when looking up modification times in order to
determine if an existing collected file should be deleted and
re-collected. By using the wrong path variable, the storage lookups
always failed, resulting in every single file being re-collected every
single time.

This reduces performance considerably, particularly with large codebases.
Since every file ends up copied, they appear as new and are recompiled.
This can result in very long page reloads on a development server,
especially if working on an older machine, in a VM, on a shared
filesystem, or on the Linux subsystem for Windows.

This is a simple change that fixes the lookup to use the correct
variable. Unit tests were added to ensure this continues to work as
expected and does not regress.

A commit made in 1.6.10 (ae6b3f8)
changed a storage lookup to use the prefixed_path variable instead of
the path variable when looking up modification times in order to
determine if an existing collected file should be deleted and
re-collected. By using the wrong path variable, the storage lookups
always failed, resulting in every single file being re-collected every
single time.

This reduces performance considerably, particularly with large codebases.
Since every file ends up copied, they appear as new and are recompiled.
This can result in very long page reloads on a development server,
especially if working on an older machine, in a VM, on a shared
filesystem, or on the Linux subsystem for Windows.

This is a simple change that fixes the lookup to use the correct
variable. Unit tests were added to ensure this continues to work as
expected and does not regress.
@cyberdelia cyberdelia merged commit 37d913d into jazzband:master Jan 15, 2017
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.

2 participants