Edgewall Software
Modify

Opened 18 years ago

Closed 15 years ago

Last modified 15 years ago

#4865 closed defect (fixed)

Interpreted InterTrac URL ignoring spaces in target names

Reported by: anonymous Owned by: Oren Held <oren@…>
Priority: normal Milestone: 0.12
Component: wiki system Version: 0.10.3
Severity: normal Keywords: intertrac bitesized
Cc: Branch:
Release Notes:
API Changes:
Internal Changes:

Description

Thanks for the tip on the strict quoting as given in #4861. That fixed the link displayed on my Wiki page. However, the interpreted URL fails because the spaces in the milestone name are ignored. The example I gave based on the Trac roadmap is bad since the milestone 0.10.4 already exists and therefore the interpreted URL would correctly function. When I try the following (with something from one of my projects):

[hlr:"milestone:1.0.0 ITC2 Ready" Milestone]

and then hover over the Milestone link, I see the preview link:

URL_to_hlr/intertrac/milestone/1.0.0 ITC2 Ready

which looks like it should work. However, when I click on the link I get an Internal Error saying Milestone 1.0.0 does not exist and the URL looks like:

URL_to_hlr/milestone/1.0.0

when it should be

URL_to_hlr/milestone/1.0.0%20ITC2%20Ready

So, the link interpreter seems to be ignoring the spaces.

Attachments (3)

trac_4865_intertrac_type1.patch (724 bytes ) - added by Oren Held <oren@…> 15 years ago.
Adds support for InterTrac links of type1: myintertrac:milestone:"my long name"
trac_4865_intertrac_type2.patch (662 bytes ) - added by Oren Held <oren@…> 15 years ago.
Adds support for InterTrac links of type2: myintertrac:"milestone:my long name"
trac_4865_intertrac_full.patch (5.2 KB ) - added by Oren Held <oren@…> 15 years ago.
This patch includes the previous two (intertrac:"type:spaced name", intertrac:type:"spaced name") ; now it also adds support for the [intertrac:wiki:"spaced name" Spaced Name] format + unittests

Download all attachments as: .zip

Change History (13)

comment:1 by Christian Boos, 18 years ago

Component: generalwiki
Milestone: 0.10.4
Owner: changed from Jonas Borgström to Christian Boos

comment:2 by Christian Boos, 17 years ago

Milestone: 0.10.50.11.1

Right, this is still an issue with 0.11: trac:"wiki:page with space".

comment:3 by Remy Blank, 15 years ago

Keywords: bitesized added

This is still an issue on current trunk.

by Oren Held <oren@…>, 15 years ago

Adds support for InterTrac links of type1: myintertrac:milestone:"my long name"

by Oren Held <oren@…>, 15 years ago

Adds support for InterTrac links of type2: myintertrac:"milestone:my long name"

comment:4 by Oren Held <oren@…>, 15 years ago

I suggest enabling all possible syntaxes:

  • type1 (patch attached)

myintertrac:milestone:"my long name"

  • type2 (patch attached)

'myintertrac:"milestone:my long name"'

  • type3 (works out of the box)

'myintertrac:"milestone:my long name"'

comment:5 by Oren Held <oren@…>, 15 years ago

I've found a bug, will fix and write tests

by Oren Held <oren@…>, 15 years ago

This patch includes the previous two (intertrac:"type:spaced name", intertrac:type:"spaced name") ; now it also adds support for the [intertrac:wiki:"spaced name" Spaced Name] format + unittests

comment:6 by Remy Blank, 15 years ago

Milestone: next-minor-0.12.x0.12

Applied a slightly simpler fix for the original issue (InterTrac links with spaces) in [9275].

I will let Christian comment on (and possibly apply) the proposed changes to the wiki syntax, as I'm not able to judge the implications.

comment:7 by Oren Held <oren@…>, 15 years ago

Alrighty,

This wiki syntax fix enables the more intuitive th:wiki:"my long name" syntax, so I think that it worth considering. It has passed the tests (neat testing system with this wiki-tests.txt!) + I've added new tests for it.

in reply to:  7 comment:8 by anonymous, 15 years ago

Owner: changed from Christian Boos to anonymous
Status: newassigned

Replying to Oren Held <oren@…>:

Alrighty,

This wiki syntax fix enables the more intuitive th:wiki:"my long name" syntax, so I think that it worth considering.

You're absolutely right with this, as we keep talking about InterTrac prefixes, it really makes sense to be able to use it as a prefix on any kind of valid TracLinks.

It has passed the tests (neat testing system with this wiki-tests.txt!) + I've added new tests for it.

I'll apply the remaining parts of the patch.

comment:9 by Christian Boos, 15 years ago

Resolution: fixed
Status: assignedclosed

Patch applied in r9284, thanks!

comment:10 by Christian Boos, 15 years ago

Owner: changed from anonymous to Oren Held <oren@…>

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Oren Held <oren@…>.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Oren Held <oren@…> to the specified user.

Add Comment


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