Edgewall Software
Modify

Ticket #3936 (closed defect: fixed)

Opened 6 years ago

Last modified 5 years ago

Wiki inconsistently interprets wiki formatting in wiki change comments

Reported by: ben@… Owned by: cboos
Priority: normal Milestone: 0.11
Component: wiki system Version: 0.10
Severity: normal Keywords: formatter context
Cc:
Release Notes:
API Changes:

Description

Make a change to the wiki and use [[PageOutline]] in its change comment. Then observe:

  1. Page History shows [[PageOutline]]
  2. Timeline shows [[PageOutline]]
  3. Page diff shows the page's outline
  4. Timeline RSS feed shows timeline's outline (!)

It would be good to pick one behavior and stick to it.

Attachments

Change History

comment:1 Changed 6 years ago by cboos

  • Keywords formatter context added
  • Milestone set to 0.11
  • Owner changed from jonas to cboos

Known issue, which can't be solved until a context information is passed to the formatter. The "right" behavior in that case would be to output the outline of the comment itself.

To be able to output the page's outline in the comment text, we probably need to have "stacked" contexts, as suggested by athomas, and a syntax to access to the parent context (e.g. [[PageOutline(..)]]).

comment:2 Changed 5 years ago by cboos

  • Resolution set to fixed
  • Status changed from new to closed

Fixed in r4451.

I should add that I finally didn't do it the way it was suggested in the comment above.
The [[PageOutline]] currently operates on the wiki text which is currently being rendered, not one some wiki text (which one?) belonging to the main resource being rendered (the one of the current WikiContext).

This means in this particular case that a [[PageOutline]] in a Wiki comment will give the outline of that comment, when rendered in wiki_to_html mode (e.g. in the Wiki diff view or when viewing that specific version of a Wiki page).

Not terribly useful in this case, but there are many other scenario where this no surprise approach will be useful. Think a big comment in a ticket, a big code review comment later on, etc.

View

Add a comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
The resolution will be deleted. Next status will be 'reopened'
to The owner will be changed from cboos. Next status will be 'closed'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.