Posts
-
Source |
Signature
Thunderbird 60, RSS feeds, HTTP 429, and `close_connection`
So, Ubuntu finally pushed Thunderbird 60 to the repos.
Which was great, because it broke so much stuff for me.
Setting aside the new icon theme (unusable due to clashing colors with a lightweight theme), the most major problem was a behavior change in how the RSS feeds were updated.
I had two groups of feeds, one for news / security notices etc. which is configured to update every 30 minutes, and another for blogs / leisure reading, updating every 24 hours. This new version decided for some reason to change them all to 100 minutes…
But that’s not all. I had a website in my daily feeds that provides multiple feeds, i.e. /rss?user=alice, /rss?user=bob, /rss?search=keyword, etc. They have also configured rate limiting in their server, which means that every 5 or so request would get an HTTP 429 (Too Many Requests). Previously this wouldn’t be a problem – due to network latency or other factors, it would probably not be the same feed getting the 429 every time. So perhaps I’ll see it a few days late, but no big deal.
But Thunderbird 60 decided that when a feed receives a network error, it should “pause” a.k.a. disable the feed, meaning that it would not check for updates for that feed ever again. Like, what?
So I figured the easiest way to “fix” this, would be to just write an HTTP proxy running on localhost, which would throttle the requests (ensure at least 100ms between each) to the server. This was done quite easily using Python.
Half an hour of coding and reading the docs later, I changed the URLs of the feeds to point to my proxy, and tried again. It didn’t work. Specifically, only the first 4 feeds worked, and the later feeds all timed out for some reason. It turned out that the
BaseHTTPRequestHandler
class doesn’t automatically close connections, and I never realised it because I’ve almost always run it multi-threaded.Preview clipped. Expand | Read full post in new tab
|
-
Source |
Signature
Worst UX ever in Google Search
So I was searching for 大埔船灣堆填區, a landfill closed in 1997, and currently rebuilt as a golf course. For some strange reason Google decides to show me a map result of 新界東北堆填區 (in the wrong language, even!), despite the correct web search results… (Note: screenshot taken after whatever follows. The little map segment on the right originally showed Ta Kwu Ling.)
(Signature)So I scrolled down that right sidebar and found a “Feedback” button. Clicking on it brings up an edit icon on each of the sidebar fields, plus a button “REPORT” for “Moved, closed or was never here”. Clicking on it brings another box…
(Signature)None of the options fix perfectly, so I just went with the one that allowed me to add a correct address. Note how there is literally NO input fields that would allow me to comment on what’s wrong. I did notice an image input though, so, under the naive assumption that a Google employee would look at the image, I uploaded this…
(Signature)Guess what that did? I have successfully changed the address of 新界東北堆填區 to Tai Po. Right now, if you search for 新界東北堆填區 in Google Maps, it would show you a marker on Ting Kok Road.
(Signature)If this doesn’t win the award for the worst UX of the year I don’t know what will.
Preview clipped. Expand | Read full post in new tab
|
-
Source |
Signature
2018-09-16
「在法庭外支持警方執法的團體宣布,本星期日將會在禮賓府外集會以示抗議。」
好呀,八號風球,唔出現正契弟
http://news.rthk.hk/rthk/ch/component/k2/1417842-20180914.htm
Preview clipped. Expand | Read full post in new tab
|
-
Source |
Signature
Coding rant
Just wrote a 51-line block comment to explain a 29-line piece of code…
Preview clipped. Expand | Read full post in new tab
|
-
Source |
Signature
<input type="time" />
Just found a bug which occurs with probability 1/60. Fixed code (MCVE):
function f() { var input = document.querySelector("input[type=time]"); var time = input.value; /* added this: */ if(time.length === "hh:mm".length) { time += ":00"; } doStuffWithTime(time); }
Preview clipped. Expand | Read full post in new tab
|
-
Source |
Signature
Starburst Stream
星爆氣流斬?
(Signature)
Image copyright Multimedia Services Ltd. Fair use.Preview clipped. Expand | Read full post in new tab
|
-
Source |
Signature
Guest WiFi at St Teresa's Hospital
Apparently, I can’t even SSH or SMTP.
tor --FascistFirewall 1 ssh -o ProxyCommand='nc -x localhost:9050 %h %p' -D9250 <myHomeServer>
Preview clipped. Expand | Read full post in new tab
|
-
Source |
Signature
今日 vs 五年前
歷史在笑
Preview clipped. Expand | Read full post in new tab
|
-
Source |
Signature
Facebook Messages underscores
Recently, Facebook Messages implemented a feature which would automatically change text surrounded by _underscores_ into italics.
This is great, until you need to type code. Then a syntactically insignificant space would change how your code looks.
Preview clipped. Expand | Read full post in new tab
|
-
Source |
Signature
LaTeX pdfpages
Package pdfpages Warning: Option `page' is unknow to \includepdf. (pdfpages) Did you mean `pages'? (Note the `s'!) (pdfpages) OK, I'll proceed as if it were `pages'.
搞咁多嘢你不如直接silently accept `page’ 咪算…
Preview clipped. Expand | Read full post in new tab
|
subscribe via RSS