Page MenuHomePhabricator

Closing bracket skipped in emailed links
Closed, ResolvedPublic


End brackets are misinterpreted as being part of the message, not the link, in Thunderbird email (and possibly others?). Hence links appear broken when clicked. e.g.:

I suggest some sort of check for closingbrackets. Perhaps when an open bracket without a closing partner is found?

Version: unspecified
Severity: enhancement



Related Objects

View Standalone Graph
This task is connected to more than 200 other tasks. Only direct parents and subtasks are shown here. Use View Standalone Graph to show more of the graph.

Event Timeline

bzimport raised the priority of this task from to Low.Nov 21 2014, 9:48 PM
bzimport set Reference to bz11056.
bzimport added a subscriber: Unknown Object (MLST).

robchur wrote:

There's really very little we can do about this. An automatic check may sound cute, but would conflict if you actually wanted the title without the closing parenthesis.

I would personally consider this a bug in the mail application, although this may be due to our "unescaping" of closing parentheses in the general URL-encoder (the line which does this *is* commented with something similar to "is this safe?")

( and ) are perfectly legitimate URL characters; like other allowed punctuation chars such as ".", though, they can play havoc with software which tries to extract URLs out of unformatted prose text.

The problem is that this is a perfectly legimitate url:

but usually in prose text if you see something this:

You can find more info at

that final '.' is intended as just punctuation for the prose text, not as part of the URL.

There are a couple of possible ways to plan for and work around this. One would be to special-case URLs that are placed into outgoing email, by looking for common punctuation chars and re-escaping them differently.

Another would be to do so for _all_ the URLs we generate, but that gives me the willies. ;)

A special-case for email would at least avoid breaking anything else.

Before doing any code, I'd recommend doing a quick survey of various e-mail clients to see how they handle some cases with trailing and embedded punctuation chars.

Isn't this fixed by simply putting URLs between <> as our messages mostly do (but not all of them)?