HTML Entity Display Bug

Under recent data on my main beeminder page I see the comments displayed including the ampersand and semicolon that make up the HTML entity e.g.

09 1 "Q&a"

The original comment I made here was just “Q&A” and the code I’ve just put into this forum page is cut’n’pasted from Beeminder’s source code.

1 Like

Nice catch! Thank you!

(This earns you stickers. DM us a postal address if you’d like them!)

I came here to report the same. Seems it hasn’t been fixed or it has regressed?

I’m trying out a goal where I was planning to extensively use ampersands in the comments, so hopefully it’s an easy fix! Thanks for looking into it.

See also Dashboard shows special character ampersand escaped

ETA: To be clear, I only see the escaped ampersand on Beeminder and on the goal detail page in the iOS app. On the website’s goal detail page, the ampersand shows up as it should.

1 Like

Alas, it isn’t an easy fix, but I confirm it’s on the radar! Thanks for letting us know it was bothersome for you – it’s always helpful to get an idea of the effect of issues like this.

1 Like

Nicky has stumbled upon the secret to goading us into fixing something!

Voila: http://beeminder.com/changelog#3901

1 Like

It sounds a lot like the way to goad me into doing something…

1 Like

Thanks @dreev! I already noticed it :wink: I also noticed some fun in-between state a couple of days ago, so I was pretty sure you were working on it (but maybe it was always like that). 1ZznViJh0Y

I’m guessing the iOS app is even a harder fix? :stuck_out_tongue: Just checking if that one is still on the radar!

1 Like

I noticed the fix on a goal where I’m using “->” in the data which now displays nicely despite the changelog only mentioning & so thank you!

This is probably barely worth mentioning but I accidentally submitted a datapoint with just a newline recently and that appears as “\n” which might be confusing to users who don’t understand control characters. Though I’m not actually sure what the best thing to display for that in a single line summary would be anyway.

1 Like

I would expect to not be able to get a newline in the datapoint at all, or if it somehow got in there, have it displayed as just a space.

1 Like

Interesting! Any chance you can figure out how to reproduce that? We’re failing to find a way to add a newline to a comment…

I can reproduce it via the API: if I submit a datapoint with a newline in it (via the API), Beeminder displays it as \n.

1 Like

Yep, I did it via the API too, comment on datapoints.json is just a string so you can send something with a newline in it. If that’s the only way to do it then I’d suggest just removing them on Beeminder’s end and documenting that that’s what’ll happen.

1 Like

Thanks for figuring this out, y’all! Arguably removing them violates anti-magic and if you’re doing this via the API then will you really be confused by seeing it rendered as “\n”? If I’m wrong then my preferred fix would probably be for the API to give an error if you try to include such characters, per anti-robustness.