Edgewall Software
Modify

Opened 15 years ago

Last modified 5 years ago

#425 new enhancement

Wiki page name need to support digits and periods

Reported by: barry.scott@… Owned by:
Priority: normal Milestone: next-major-releases
Component: wiki system Version: 0.8
Severity: normal Keywords:
Cc: Branch:
Release Notes:
API Changes:

Description

Restricting Wiki page names to only alphabetic chars makes it very have to create pages that discuss MilestoneV1.0 etc

Is there any problem with allowing digits and period?

Attachments (0)

Change History (19)

comment:1 by Jonas Borgström, 15 years ago

Milestone: 0.7.1
Status: newassigned

Good point, I just think this is something we've overlooked.

comment:2 by anonymous, 15 years ago

[560] adds support for digits in CamelCase-names. I'm not sure if it's a good thing to allow periods as well.

This change should be merged into 0.7-stable before this ticket is closed.

comment:3 by Jonas Borgström, 15 years ago

Resolution: fixed
Status: assignedclosed

I changed my mind and added support for periods as well.

Fixed in both trunk and 0.7-stable.

comment:4 by anonymous, 15 years ago

This feature appears to have been removed in 0.8 (presumably related to ticket #775).

comment:5 by cboos@…, 15 years ago

Component: generalwiki
Milestone: 0.7.1
Resolution: fixed
Status: closedreopened
Version: 0.6.10.8

I didn't know about these tickets, and ended up implementing it for myself…

I think this depends on the software being worked on. Here we have a product suite with 3D in the name. It would be rather annoying to spell each related wiki page ThreeD something…

What about making this feature configurable?

[wiki]
allow_digits_in_name = 1

comment:6 by Christopher Lenz, 15 years ago

Note that ThreeD isn't a valid wiki name either, it'd have to be ThreeDee.

So we want to avoid that names such as A0B1 (the example from #775) are recognized as wiki page names. Quite obviously A0B1 has nothing camel-ish to it.

One option would be to treat digits as uppercase characters. So A0B1 would not be a wiki name, but 1a2b would be. So you could use e.g. 3d as a wiki page names. Does that feel right? I'm not sure.

And for what it's worth, I'm not really in favor of adding configuration options that alter the wiki syntax like this.

comment:7 by cboos@…, 15 years ago

One option would be to treat digits as uppercase characters.

That would help, but it would be useful to have consecutive digits:

  • AboutUnigraphics21
  • Jbuilder2005News
  • Lotus123isObsolete
  • Our3dApp
  • ReleaseNotes8200

The following:

!python
   # ...
   wiki = r"""(?P<wikilink>!?(^|(?<=[^A-Za-z\d]))[A-Z][a-z][a-z\d]*(?:[A-Z][a-z\d]*[a-z\d/])+(?=\Z|\s|[.,;:!?\)}\]]))"""

matches all of the above and none of #775.

It is still quite easy to fool, like with Aa1B0. But then, AaxZqerzW" doesn't look to be a valid wiki page name from a human perspective either…

comment:8 by cboos@…, 15 years ago

Sorry, I just saw that I added another messed up comment! One day, I will use the Preview feature, promised :). In the meantime I'll work on edit/delete action for comments, along the line of what I did in #948 for the attachments…

comment:9 by Christian Boos, 14 years ago

Owner: changed from Jonas Borgström to Christian Boos
Status: reopenednew

The upcoming InterTrac related wiki refactoring will enable the creation of alternate WikiPageNames rules. As examples, I'll write one that integrates my old proposal above, and one that follows the SubWiki rules.

comment:10 by Christian Boos, 14 years ago

Severity: normalenhancement
Status: newassigned

Implemented in r2005 (InterTrac branch)

comment:11 by Christian Boos, 14 years ago

Milestone: 1.0
Severity: normalminor

Should I backport the above to the trunk?

comment:12 by Matthew Good, 14 years ago

Well, there seems to be a lot of debate about automatic CamelCase linking right now and I think that mixing in possibilities for digits, etc. will possibly match even weirder page names like cmlenz mentioned above that don't really make sense as WikiNames.

I think that we should put requests for changes to the CamelCase criteria on hold to discuss it a bit. Since it's pretty easy now to use [wiki:MilestoneV1.0] I don't really see a reason to add this complexity to the CamelCase matching.

comment:13 by Matthew Good, 14 years ago

I should also not that milestone pages can already contain Wiki content, so creating a separate Wiki page for a milestone is probably not a good idea and the relevant information should just be put on the milestone page such as milestone:1.0

comment:14 by Christian Boos, 14 years ago

Priority: normalhigh
Severity: minornormal

See also FlexibleWikiPageNames.

The particular syntax that would allow as Wiki page names:

  • AboutUnigraphics21
  • Jbuilder2005News
  • Lotus123isObsolete
  • Our3dApp
  • ReleaseNotes8200

(but none of A0B1, ST62T53C6, IR32V1H000, the examples from #775), can be enabled by modifying the [components] section of the TracIni in the following way:

[components]
# Standard Trac WikiPageNames rule
trac.wiki.api.StandardWikiPageNames = disabled
# Standard Trac WikiPageNames rule, plus digits
trac.wiki.api.FlexibleWikiPageNames = enabled
# SubWiki-like rules for WikiPageNames.
trac.wiki.api.SubWikiPageNames = disabled

in reply to:  description comment:15 by anonymous, 13 years ago

Replying to barry.scott@onelan.co.uk:

Restricting Wiki page names to only alphabetic chars makes it very have to create pages that discuss MilestoneV1.0 etc

Is there any problem with allowing digits and period?

that's no problem.

comment:16 by Christian Boos, 10 years ago

In #8119, another user took for granted that digits were allowed in a wiki page name…

comment:17 by Christian Boos, 9 years ago

Milestone: 1.0unscheduled

Milestone 1.0 deleted

comment:18 by Christian Boos, 9 years ago

Milestone: triagingnext-major-0.1X
Priority: highnormal

Still interested in that, in the longer term.

comment:19 by Ryan J Ollos, 5 years ago

Owner: Christian Boos removed
Status: assignednew

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The ticket will remain with no owner.
The ticket will be disowned. Next status will be 'new'.
as The resolution will be set. Next status will be 'closed'.
The owner will be changed from (none) to anonymous. Next status will be 'assigned'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.