-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
[WIP] Remove comments app #3802
Conversation
readthedocs.comments.models.ModerationActionManager is unimplemented. This is a cleanup issue. Closes readthedocs#2879
@@ -136,6 +136,7 @@ class Project(models.Model): | |||
'DirectoryHTMLBuilder">More info</a>.')) | |||
|
|||
# Project features | |||
# TODO: remove this? | |||
allow_comments = models.BooleanField(_('Allow Comments'), default=False) | |||
comment_moderation = models.BooleanField( |
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.
Are this fields part of the comment app?
allow_comments
and comment_moderation
.
I'm going to see if the tests explode if I remove those lines.
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.
Probably should be removed also. Can you grep the code by allow_comments
and comment_moderation
to see where it's used?
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.
Relevant files
Here is used to choose the sphinx builder
https://github.com/rtfd/readthedocs.org/blob/aefa1b6067f87e2551d8a0e1254ec545b94008d4/readthedocs/doc_builder/backends/sphinx.py#L217-L218
No relevant files
Just to show on the dj admin
https://github.com/rtfd/readthedocs.org/blob/aefa1b6067f87e2551d8a0e1254ec545b94008d4/readthedocs/projects/admin.py#L105-L106
Here is just a comment
https://github.com/rtfd/readthedocs.org/blob/aefa1b6067f87e2551d8a0e1254ec545b94008d4/readthedocs/projects/forms.py#L232-L234
On a template to link to the comments section
https://github.com/rtfd/readthedocs.org/blob/aefa1b6067f87e2551d8a0e1254ec545b94008d4/readthedocs/templates/projects/project_edit_base.html#L28-L30
For the comment_moderation there is a template that is very related to the comment model. I think that should be removed without problem, but now I'm curious about the sphinx builder.
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.
I remove stuff related to comment_moderation
, and I see that is very related to allow_comments
, but I'm have doubts about this
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.
I think we can safely remove that readthedocs-comments
builder and all the -comments
builders.
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.
Yep, it can all be removed.
Also we want to remove the comments builder from https://github.com/rtfd/readthedocs-sphinx-ext (I'm not familiar with that repo) |
I suppose that you can remove the whole |
Yea, I have an initial PR doing this that could be improved (readthedocs/readthedocs-sphinx-ext#31) |
@stsewd would you like to finish Eric's PR in the other repo so we can go forward whith this one also? |
Blocked by: readthedocs/readthedocs-sphinx-ext#38 |
Merging this, and we can figure out if it has further issues during dev today before deploying it. |
🙏 @stsewd |
The only thing missing here are the migrations, I think I can add them to #3608 |
PR on top of #3618 (#3618 (comment))
Closes #2879