Open
Conversation
9cf4e01 to
e28f19c
Compare
Contributor
Author
|
If I don't have any reviews or feedback on this by next week I'll take that as tacit approval and merge it, then push a tag and release a new version of django-dbtemplates. |
vied12
added a commit
to Codepan-GmbH/django-dbtemplates
that referenced
this pull request
Jul 28, 2025
vied12
added a commit
to Codepan-GmbH/django-dbtemplates
that referenced
this pull request
Jul 28, 2025
This file contains hidden or 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
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.
In the first commit:
setting_changedsignal to connect and disconnect theadd_default_sitesignal handler during testspathlib.Path, since that API is much nicer than theos.pathAPI, which let me simplify some file writing and reading later on, since we can usePath.read_text()andPath.write_text()instead of manually using context managers to open files for reading and writing.assertInandassertQuerySetEqual.override_settingdecorator andself.settings()context manager to automatically handle changing settings during tests, and resetting to the previous values after those tests finish.In the second commit:
TestCases according to what piece of dbtemplates they test.test_settings.pyto fit more modern Django settings modules (read: useCACHESinstead of configuring a cache backend directly).Template.populate()method a little bit to improve readability by using try/except/else.pathlib.Pathin thesync_templatescommand.dbtemplates/utils/templates.pyto properly record the chain of loaders that were tried when finding a template.Then I formatted a bunch of files with Ruff.
Once this is merged I'll submit a commit/PR that updates the changelog and then merge and tag it so a new version gets released to PyPI.