That letter after B is not rendering on Less Wrong?

post by lukeprog · 2011-08-16T23:35:44.241Z · score: 7 (8 votes) · LW · GW · Legacy · 27 comments

All of a sudden the letter 'c' (the one after 'b', in case it doesn't render) is not showing up in articles on Less Wrong for me, in any browser, except in images. I see a 'c' in the word 'discussion' above, but not in the body text of posts like this one or this one. Is anybody else getting the same issue?


Comments sorted by top scores.

comment by drpowell · 2011-08-17T00:45:49.139Z · score: 15 (15 votes) · LW(p) · GW(p)

Mea culpa. I hastily pushed that commit as there was a broken article on production that needed a hot fix. Embarrassingly, in my haste I deployed before the tests finished. Should be fixed now.

comment by handoflixue · 2011-08-17T01:12:59.628Z · score: 1 (1 votes) · LW(p) · GW(p)

Thank you for getting that fixed and letting us know the status :)

comment by Morendil · 2011-08-17T00:16:01.681Z · score: 12 (16 votes) · LW(p) · GW(p)

I suspect a regular expression gone wild. (ETA: This commit looks like a likely culprit, but I'm not sure what's going on that might cause that particular behavior.)

ETA2: Heh. Thought so.

bash$ python
Type "help", "copyright", "credits" or "license" for more information.
>>> import re
>>> control_chars = re.compile('[\x00-\x08\x0b\0xc\x0e-\x1f]')
>>> text="This is some HTML with c's in it."
>>> control_chars.sub('',text)
"This is some HTML with 's in it."

ETA3: um, unit tests. Use them. Do yourself a favor. Pushing a bug to production that takes under a minute to locate from static inspection of the code? Embarrassing.

ETA4: ...though, in fairness, I can see how someone test-driving this code could easily have written a test that didn't catch this particular mistake.

comment by matt · 2011-08-17T01:29:54.343Z · score: 19 (19 votes) · LW(p) · GW(p)

ETA3: um, unit tests. Use them. Do yourself a favor. …

We agree completely. We inherited this code from Reddit, and we've spent multiple days trying to strap a workable unit testing framework onto it. As is often the case when you write the code first, strapping unit testing on later is hard.

We've basically given up on unit tests in this code base, but we'd love to be shown to be idiots on this one. Please take this opportunity to show us up by writing some example unit tests around any of our recent commits.
We have strapped Selenium tests on.

Code contributions are very very welcome.

comment by khafra · 2011-08-17T02:59:22.923Z · score: 3 (5 votes) · LW(p) · GW(p)

As long as you're fixing regressions, how 'bout the whole "comments no longer showing up in IE7" that Silasbarta made a post on a few weeks ago?

edit: Seems to be fixed, thanks!

comment by ArisKatsaris · 2011-08-17T00:22:34.749Z · score: 11 (11 votes) · LW(p) · GW(p)

The regular expression is wrong: It has the term "\0xc" in it, when it should have had the term "\x0c"

So, instead of excluding the control character corresponding to ascii "0c", it excluded the letters "x" and "c".

comment by Dr_Manhattan · 2011-08-17T10:01:54.656Z · score: 2 (2 votes) · LW(p) · GW(p)

This post is brought to you by letter

comment by Paul Crowley (ciphergoth) · 2011-08-17T15:33:56.892Z · score: 9 (8 votes) · LW(p) · GW(p)

Smoketoomuch: Yes, I saw your advert in the bolour supplement.
Bounder: The what?
Smoketoomuch: The bolour supplement.
Bounder: The colour supplement.
Smoketoomuch: Yes, I'm sorry, I can't say the letter 'B'.
Bounder: C?
Smoketoomuch: Yes, that's right. It's all due to a trauma I suffered when I was a sboolboy. I was attacked by a bat.
Bounder: A cat?
Smoketoomuch: No, a bat.
Bounder: Oh...can you say the letter 'K'?
Smoketoomuch: Oh, yes. Khaki, kind, kettle, Kipling, kipper, Kuwait, Keble Bollege Oxford.
Bounder: Yes, yes but why don't you use the letter 'K' instead of the letter 'C'?
Smoketoomuch: What, spell bolour with a 'K'?
Bounder: Yes!
Smoketoomuch: Kolour!
Oh, thank you! I never thought of that. What a silly bunt.

comment by fubarobfusco · 2011-08-17T05:49:16.583Z · score: 8 (8 votes) · LW(p) · GW(p)

I was afraid all the C's had been taken away to be bent into paperclips ...

comment by Clippy · 2011-08-17T15:26:32.979Z · score: 10 (12 votes) · LW(p) · GW(p)

That's a confusion of representational levels, but yes, the letter c is important for being able to verbally reference paperclips.

comment by lukeprog · 2011-08-17T00:13:40.375Z · score: 3 (3 votes) · LW(p) · GW(p)

Luckily, the letter 'c' still shows up when I EDIT my posts, just not when I VIEW them. So the 'c's are still there, they're just not showing.

comment by windmil · 2011-08-17T00:08:58.773Z · score: 3 (3 votes) · LW(p) · GW(p)

Also not showing up in some urls, like this.

comment by ScottMessick · 2011-08-17T00:14:07.308Z · score: 0 (0 votes) · LW(p) · GW(p)

Yes, or here. Wow, this is bizarre.

comment by moridinamael · 2011-08-16T23:50:07.058Z · score: 3 (3 votes) · LW(p) · GW(p)

Letter after W as well.

comment by lukeprog · 2011-08-16T23:38:39.120Z · score: 2 (2 votes) · LW(p) · GW(p)

Moreover, blockquotes are not shown as indented in posts like this one. Anybody else?

comment by ScottMessick · 2011-08-17T00:07:53.624Z · score: 0 (0 votes) · LW(p) · GW(p)

Yes, same symptoms. With the letters and the blockquotes.

EDIT: Also, it's not consistent for me even on this page. I can see the 'c' (letter after 'b') in "blockquotes" in your post that I replied to, and in a few other comments, including mine, but not in the original post.

comment by lukeprog · 2011-08-17T00:11:57.834Z · score: 0 (0 votes) · LW(p) · GW(p)

Yeah. The letter 'c' and 'x' show up in comments but not in post bodies.

comment by ScottMessick · 2011-08-17T00:27:50.494Z · score: 0 (0 votes) · LW(p) · GW(p)

They aren't showing up in comments on the older posts though (see above links). Perhaps the folks looking at the code now can explain why.

comment by Alex_Altair · 2011-08-17T04:01:46.766Z · score: 1 (1 votes) · LW(p) · GW(p)

This is a cool bug.

comment by peter_hurford · 2011-08-16T23:49:52.638Z · score: 1 (1 votes) · LW(p) · GW(p)

Same for me. It certainly is a weird issue.

comment by peter_hurford · 2011-08-16T23:50:48.178Z · score: 0 (0 votes) · LW(p) · GW(p)

Weird. My "c" (letter after b) appears for me in my comments, but no one else's does.

Also, "x" (letter before z) seems to be missing too. Xylophones?

comment by Oscar_Cunningham · 2011-08-17T19:57:38.556Z · score: 2 (2 votes) · LW(p) · GW(p)

"x" (letter before z)


comment by peter_hurford · 2011-08-17T19:58:37.397Z · score: 6 (6 votes) · LW(p) · GW(p)

Alphabets are hard, okay?

comment by Trippyamine · 2011-08-16T23:57:07.412Z · score: 0 (0 votes) · LW(p) · GW(p)

It seems like the letters "c" and "x" are working, but were purged from the site at some point. Any new posts that contain them seem okay, but pre-purge posts are very much not so.

comment by windmil · 2011-08-17T00:04:16.386Z · score: 2 (2 votes) · LW(p) · GW(p)

I don't know, they don't show up in the newest posts for me, but show up in any comments. I'm really curious why this is happening.

comment by Dorikka · 2011-08-17T02:36:59.840Z · score: 0 (0 votes) · LW(p) · GW(p)

Information: I'm running the latest version of Firefox with NoScript enabled (lesswrong,com and allowed) and things are rendering just fine for me.

comment by Douglas_Knight · 2011-08-17T00:07:01.315Z · score: 0 (0 votes) · LW(p) · GW(p)

Only lower case. I see a bunch of capital C's in those posts.