Talk:Moon/Row

From Kerbal Space Program Wiki
Revision as of 11:15, 16 March 2015 by XZise (talk | contribs) (Expression error: Unrecognized punctuation character "{".)
Jump to: navigation, search

Expression error: Unrecognized punctuation character "{".

This occurs at the Sigfigs template. Oddly, erasing one "{" in front of it makes the error quiet down, but near as I can tell that would be one too few "{"s to match the "}"s. So, I think the error may be in how Template:Sigfigs returns things. This is a little technical for me... --Brendan (talk) 23:31, 13 March 2015 (CDT)

Where does the error occur? Looking at your fix I doubt that it works. — xZise [talk] 12:52, 14 March 2015 (CDT)
Revert the fix and it will appear here, and also when all the <noinclue> & <includeonly> tags are removed from the Sigfig template. The numbers parsed through Sigfig seem to all work with my attempted fix, so... what do you think? --Brendan (talk) 12:55, 14 March 2015 (CDT)
You made it to triple brackets which interpret it as a variable: Oh vs. No ({{{#ifexpr: 42 = 0|Oh|No}}} vs. {{#ifexpr: 42 = 0|Oh|No}}). It returns “Oh” in the first case because the variable “#ifexpr: 42 = 0” is not set (although that name doesn't make sense with the equal sign in it). And if a variable is not set it uses the first parameter after it (“Oh”, interestingly it doesn't use everything after the pipe). This here is also a meta template. The data is missing here so it can't show anything useful. If a variable is not set and also no default (e.g. {{{foobar}}}) then it'll display the text unchanged (so {{{foobar}}}) and the curly brackets are not a valid number.
You've now changed it into a variable which seems to have disabled calculating with it and thus no apparent errors. But when I substitute {{sigfigs|1|4}} you see that it's using the scientific notation even though the number is shorter than the given significant figures: 1.000×100xZise [talk] 06:15, 16 March 2015 (CDT)