-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Replace DebugConfiguredStorage with URLMixin in staticfiles panel #2097
Merged
matthiask
merged 26 commits into
django-commons:main
from
dr-rompecabezas:add-tests-for-2068
Mar 5, 2025
Merged
Replace DebugConfiguredStorage with URLMixin in staticfiles panel #2097
matthiask
merged 26 commits into
django-commons:main
from
dr-rompecabezas:add-tests-for-2068
Mar 5, 2025
+66
−44
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading status checks…
…asses
- Test storage state preservation to ensure URLMixin doesn't affect storage attributes - Test context variable lifecycle for static file tracking - Test multiple initialization safety to prevent URLMixin stacking
2 tasks
matthiask
approved these changes
Mar 5, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks great!
Now we just need a note in docs/changes.rst
and a ready-to-review PR (no need to mark it as a draft anymore!) and it's good to go.
updates: - [github.com/adamchainz/django-upgrade: 1.22.2 → 1.23.1](adamchainz/django-upgrade@1.22.2...1.23.1) - [github.com/pre-commit/mirrors-eslint: v9.19.0 → v9.20.0](pre-commit/mirrors-eslint@v9.19.0...v9.20.0) - [github.com/astral-sh/ruff-pre-commit: v0.9.4 → v0.9.6](astral-sh/ruff-pre-commit@v0.9.4...v0.9.6) Signed-off-by: Matthias Kestenholz <mk@feinheit.ch>
…2078) * Update package metadata to include well-known labels
The issue has been reported upstream, for now we just want passing tests. Refs django-commons#2082.
* [pre-commit.ci] pre-commit autoupdate updates: - [github.com/pre-commit/mirrors-eslint: v9.20.0 → v9.21.0](pre-commit/mirrors-eslint@v9.20.0...v9.21.0) - [github.com/astral-sh/ruff-pre-commit: v0.9.6 → v0.9.7](astral-sh/ruff-pre-commit@v0.9.6...v0.9.7) * Update the ESLint dependency --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Matthias Kestenholz <mk@feinheit.ch>
This adds a new section to the documentation, "Resources", which provides a curated list of tutorials and talks. - Favor conference site links and DjangoTV over YouTube - Make the invitation to contribute more inviting - Remove the criteria for inclusion and contributing sections
…mmons#2066) This checks if the SHOW_TOOLBAR_CALLBACK is a coroutine if we're in async mode and the reverse if it's not. It will automatically wrap the function with sync_to_async or async_to_sync when necessary. * ASGI check approach with added test and docs * async compatible require_toolbar and tests * add docs for async require_toolbar --------- Co-authored-by: Aman Pandey <aman2001mi@gmail.com>
biome is faster and nicer to configure with pre-commit. Closes django-commons#2065.
The way how they do not override the value of 'this' makes implementing handlers and callbacks so nuch nicer.
updates: - [github.com/astral-sh/ruff-pre-commit: v0.9.7 → v0.9.9](astral-sh/ruff-pre-commit@v0.9.7...v0.9.9) - [github.com/tox-dev/pyproject-fmt: v2.5.0 → v2.5.1](tox-dev/pyproject-fmt@v2.5.0...v2.5.1) Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
5b30ea9
to
5a3b805
Compare
for more information, see https://pre-commit.ci
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This PR supersedes #2069
Fixes #2068
From @matthiask : This change might address an issue where reinstantiating the staticfiles class inside our staticfiles panel would lose some attributes of the storage instance.
Tests added by @dr-rompecabezas
Checklist:
docs/changes.rst
.