Page MenuHomePhabricator

ParserFunctions: Make MAX_TIME_CHARS configurable
Open, Needs TriagePublicFeature

Description

Currently MAX_TIME_CHARS is hardcoded to 6000. This makes it sometimes cause 'Error: Too many #time calls' for no good reason. In TDF wiki this can currently be seen here thanks to this template.

I found an older discussion thread about the issue pointing to the root of the problem.

Event Timeline

Now I noticed a discussion where it is said:

That error occurs not just when any format text is 6000 characters or greater, it occurs when the total length of the format parameter to all calls exceeds 6000. Notice that the length is accumulating via self::$mTimeChars += strlen( $format );. For whatever reason, that function has been designed to be self-limited in a fashion similar to an expensive parser function, but not actually part of that mechanism.