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

docs(history): add documentation on some management commands #1110

Conversation

sennierer
Copy link
Collaborator

resolves #873

@sennierer sennierer requested a review from koeaw August 27, 2024 12:54
docs/source/features.rst Outdated Show resolved Hide resolved

python manage.py clean_duplicate_history --auto

This command will clean up duplicate history entries.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could there be a 1-sentence or half sentence explanation about duplicates added?

Why are there duplicates/how do they come about/why do they need cleaning? Or alternatively a link to where the django-simple-history docs talk about them.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I dont think that there is an answer to this. Depending on your code you might call save on an object twice (eg via signals) and get duplicates. This management command just checks whether there are exactly the same objects in your history tables and removed one.

Comment on lines +75 to +85


Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All of the commands mentioned feature the argument --auto, but its purpose is never explained.

Would add a note either to the description of the first command (first appearance) or here at the end – or leave if off altogether (if possible/sensible).

@sennierer
Copy link
Collaborator Author

Ran the whole part of the documentation through an LLM to improve writing and structure.

@sennierer sennierer force-pushed the ms/873-Document-management-command-for-activating-history-module branch from 9a41aa5 to 804e188 Compare October 4, 2024 09:32
@sennierer sennierer requested a review from koeaw October 8, 2024 11:42
@sennierer sennierer force-pushed the ms/873-Document-management-command-for-activating-history-module branch from 804e188 to 14350dc Compare December 10, 2024 15:24
@sennierer sennierer merged commit 320e73f into main Dec 10, 2024
15 checks passed
@sennierer sennierer deleted the ms/873-Document-management-command-for-activating-history-module branch December 10, 2024 15:32
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.

Document management command for activating history module
3 participants