Revision history [back]
question.html vs question.summary
We are migrating an old askbot website: the answers and comments disapeared and the questions are shortened.
The problem seems to be the following: instead of using the html
column of
the (new) askbot_post
table, the website looks for the summary
column of
the same field, and since answers and comments have an empty summary, this
explains both issues.
Indeed, if we replace:
{{ question.summary }}
by{{ question.html }}
in theaskbot/templates/question/question_card.html
file{{ answer.summary }}
by{{ answer.html }}
in theaskbot/templates/question/answer_card.html
file{{ comment.summary }}
by{{ comment.html }}
in theaskbot/templates/macros.html
file
Then we have a good website. It seems that the change that creates this problem is the following change (sorry, not enough karma to post a link : github.com/ASKBOT/askbot-devel/commit/0705ba63df2c3bf540109d52072c47317b3c105c
Moreover, the previous contents of the column summary
of the askbot_post
table are text, while the new settings, they are html.
Here are my questions.
- Why is
.summary
replacing.html
in the templates ? - In the current setting, is there a difference between the columns
html
andsummary
in theaskbot_post
table ? - If those columns are different, how to rebuild the old summary column according to the new convention (otherwise i can simply copy the html column over the summary column) ?
- Is there a plan to support such a migration officially, so that we do not have to fork the code ?
- What are the long term plans for those columns ?
question.html vs question.summary
We are migrating an old askbot website: the answers and comments disapeared and the questions are shortened.
The problem seems to be the following: instead of using the html
column of
the (new) askbot_post
table, the website looks for the summary
column of
the same field, and since answers and comments have an empty summary, this
explains both issues.
Indeed, if we replace:
{{ question.summary }}
by{{ question.html }}
in theaskbot/templates/question/question_card.html
file{{ answer.summary }}
by{{ answer.html }}
in theaskbot/templates/question/answer_card.html
file{{ comment.summary }}
by{{ comment.html }}
in theaskbot/templates/macros.html
file
Then we have a good website. It seems that the change that creates this problem is the following change (sorry, not enough karma to post a link : github.com/ASKBOT/askbot-devel/commit/0705ba63df2c3bf540109d52072c47317b3c105c
Moreover, the previous contents of the column summary
of the askbot_post
table are text, while the new settings, they are html.
Here are my questions.
- Why is
.summary
replacing.html
in the templates ? - In the current setting, is there a difference between the columns
html
andsummary
in theaskbot_post
table ? - If those columns are different, how to rebuild the old summary column according to the new convention (otherwise i can simply copy
the html column over the summary column)them) ? - Is there a plan to support such a migration officially, so that we do not have to fork the code ?
- What are the long term plans for those columns ?
question.html vs question.summary
We are migrating an old askbot website: the answers and comments disapeared and the questions are shortened.
The problem seems to be the following: instead of using the 'html' column of
the (new) html
'askbot_post' table, the website looks for the askbot_post
'summary' column of
the same field, and since answers and comments have an empty summary, this
explains both issues.summary
Indeed, if we replace:
{{ question.summary}}}} by{{ question.html}}}} in theaskbot/templates/question/question_card.html fileaskbot/templates/question/question_card.html
{{ answers.summary }} by{{ answer.summary }}
{{ answers.html }} in the{{ answer.html }}
askbot/templates/question/answer_card.html fileaskbot/templates/question/answer_card.html
{{ comment.summary}}}} by{{ comment.html}} in the}} in the askbot/templates/macros.html fileaskbot/templates/macros.html
Then we have a good website. It seems that the change that creates this problem is the following change (sorry, not enough karma to post a link : github.com/ASKBOT/askbot-devel/commit/0705ba63df2c3bf540109d52072c47317b3c105c
Moreover, the previous contents of the column askbot_post.summary are text,
while the new summary
of the askbot_post
table are text, settings, they are html.
- Why is
.summary replacing.summary
.html in the templates ?.html
- In the current setting, is there a difference between the columns
askbot_post.html and askbot_post.summary ?html
andsummary
in theaskbot_post
table - If those columns are different, how to rebuild the old summary column according to the new convention (otherwise i can simply copy them) ?
- Is there a plan to support such a migration officially, so that we do not have to fork the code ?
- What are the long term plans for those columns ?