Description

Using #Deprecated causes the content of the page to render twice!

Using #Deprecated causes the content of the page to render twice!

Your task is to find and fix docs and wiki pages talking about this feature, add clarifications about how it works, close this bug. #Deprecated is a PI (see HelpOnProcessingInstructions).

You will have to do the editing on this wiki and on MoinMaster (see EditingOnMoinMaster).

This task needs about 10h of work and has to be completed within 7 days.

Steps to reproduce

  1. Create a page with some text
  2. Save
  3. Edit again, add #Deprecated at the top
  4. Save

Example

Details

This wiki

Workaround

Discussion

I fixed this somewhere before 1.3. This seems to me a problem with the changed revisioning system. -- OliverGraf 2004-12-14 08:08:34

Hmmm, anybody noted this is a feature, not a bug? AT least at the time it was implemented... -- JürgenHermann 2005-09-25 17:42:03

Confirmed as defect for MoinMoin version 1.5.4 [Revision a166ae34993c+ tip] (Python Version 2.4.3 (#3, May 1 2006, 15:34:50) [GCC 3.3.5 (Debian 1:3.3.5-13)]). -- MartinBayer 2006-07-28 16:28:48

The deprecated feature should be used like this:

  1. Edit the deprecated page
  2. Add #deprecated processing instruction at the top
  3. Delete the deprecated content
  4. Explain why the page was deprecated and link to page replacing this page
  5. Save

After saving, the page would show the explanation and the deprecated content from the previous revision. Further editing will not create new revisions.

You can get similar effect without using this feature. Just add similar explanation in the top of the page and link to the replacement page.

One problem with the deprecated feature is changing the content of an older revision. To do that, you have to revert to the older revision, edit it, then deprecate the page again.

About your comments:

  1. Not consistent - true
  2. A page marked as DEPRECATED shouldn't be editable in the first place - of course it should be. I find it unacceptable if not :)

  3. Marking a page as DEPRECATED is more or less the same as deleting - no, when you delete a page the name is freed and the content disappear. The purpose of DEPRECATED is to keep the name and content, but warn the reader that this content is DEPRECATED.

  4. this is why its content should be ignored from any search - I don't think it should be ignored from search. It is not consistent and too magical.

  5. If there is a pages that replaces the deprecated page, just put a link to it in the page or make it a REDIRECT - redirect is not a replacement for DEPRECATED because it hides the redirect page.

  6. delete-but-keep - you contradict yourself, either delete or keep :)

This feature sucks and poorly documented - I understood it only by reading the code :) but it is not a bug.

This is not a bug, but a feature. You are not supposed to simply add #deprecated to an existing page, but rather remove the contents of the page, add #deprecated at the top, and then type a short reason explaining the deprecation. (This comment was added by FedLor on 2007-12-24 16:56:53)

#deprecated Password protection is deprecated, use ACLs instead.
Password protected pages are really cool!

-- FedLor 2007-12-25 15:07:17

MartinBayer->ThomasWaldmann: to refer to the documentation, or implementation details is without any use here.
The parser does not what the user expects from it, because he sees some content on a page that he is unable to find in the page's source. I didn't say that this does not work as designed. But that does not change the fact that the current behaviour is wrong from a users perspective—and thus a bug (call it “broken by design”, if you prefer).
We should therefore first modify the #deprecated parser so that it does not double the pages content any more. That would solve this issue. After that, I suggest to think about the future of #deprecated in a more general way, as I haven't seen really sensible use cases for it till now. 2007-12-26 12:22:03

Plan

See Also


CategoryMoinMoinNoBug

MoinMoin: MoinMoinBugs/DeprecatedDoubleContent (last edited 2007-12-26 22:19:17 by ThomasWaldmann)