Day 90 - Goodbye Capture Groups, Hello Word Boundaries

There was an interesting Regex problem to solve today. Insert commas in a number according to the Indian numbering system. There’s an inherent asymmetry in the Indian system

The number: 1 million

Indian: Rs. 10,00,000 American: Rs. 1,000,000

The first approach that I took was to use capture groups. Capture the last three digits, put a comma in front of them, then the next two and so on. This would have worked if all the numbers that this replacement needed to happen on were of the same number of digits. That kind of thing never happens in real life.

Scouring the internet, I eventually landed on the Regex used to insert commas according to the American system. The regex looked... Read More

Day 89 - 4 chapters into Daughter of Time. Where is this book going?

I have read four chapters of Daughter of Time now. It is going good till now, I have absolutely no clue about the history or England. A cursory reading of the Wikipedia pages of House York and Richard III himself, took care of that (partially). The story itself is going to probably revolve around Richard III, his brother Edward, the two nephews, Tyrell and two of his hench men.

The way everyone has a new story or a new view point to add to the story of Richard III is totally in line with how History is as one chooses to see it. As a friend of mine put it one fine evening, over dinner, “All objectivity is lost when... Read More

Day 88 - Query population with refPath works. What went wrong?

I have been delving into Mongoose and Lodash rather heavily in the past few days. A strange thing that I found with Mongoose Query Population was that the dynamic referencing of the model to populate from, to be done using refPath in the Schema, didn’t work for multiple documents. (or so I thought! Read on.)

The same thing worked for a single document. I decided to conduct an isolated test to check if this was a problem, or if we were simply using it wrong. The test worked well, it isn’t a problem with mongoose. (I am still no closer to figuring out what the anomaly in the original use-case was)

This was the javascript for the... Read More

Day 87 - Metakgp Wiki goes down and comes back up; Script to snapshot each week

Next up: Daughter of Time by Josephine Tey. I was going to read Dennis Lehane’s Mystic River (because Donna Tartt said that that was the book that pushed her to write Secret History), but it was about 350 or 450 pages or something, and I wanted to stick to smaller books which I can be reasonably sure I would complete than involve myself in a huge book which I would be rather skeptical about completing.

The setting for Daughter of Time is peculiar, apparently, it’s an analysis / investigation of a painting and a murder by an investigator on his hospital bed for 2 days (or more? The whole book, basically). I am a little nervous about whether I would... Read More

Day 86 - Cruising Attitude - A list of the things I learnt about flight atttendants and flying

I finished reading Cruising Attitude today! It was a really easy read, with lots of light hearted humor and some really gruesome experiences, both of the author herslef and her friends, who play a major role throughout the book.

There are a lot of things about the flight attendant profession that I learnt from the book, I can’t make an accurate, exhaustive list of them, but I will try to make some list that I can refer back to, later:

  • They get paid far less than everyone thinks they do
  • They have to bring their own food from home because the snacks on a flight are not for them and they can eat first class food, ONLY if it... Read More

Day 85 - Devastating global ransomware attack(??), Node.js event loop

A global ransomware attack and the oppurtunity to see it play out in real time? Wow, that’s scary and exciting, no offence to everyone who was affected. It sucks big time, but as someone who is fascinated by how these things start and how they spread, it is particularly of interest to me.

The exploit was a Windows port 445 SMB loophole that the NSA apparently knew about but disclosed to everyone only after their recent leak. Snowden quickly took to twitter to criticise them for reducing the amount of time that everyone had to prepare because they disclosed the exploit’s existence so late.

The way it spread (and the way people were affected) is of more interest to me,... Read More

Day 84 - Handmaid's Tale Audiobook is here! (+ Claire Danes)

img

I just recieved the 2012 audiobook version of Handmaid’s Tale. AND I LOVE IT.

I have tried one audiobook before: The Hitchhiker’s guide to the Galaxy. I didn’t like the book as much as everyone else told me they did. I don’t know if it was the weird setting, or an immaturity on my part to appreciate fantasy-ish literature. I know there’s a proper word for that, I can’t remember it now though.

I started hearing the audiobook. They have done a good job of telling people exactly how to move the files onto an iPod and I was able to do it in about 10 minutes with an old Windows 7 laptop. (In retrospect, with... Read More

Day 83 - StartPage search? P.S. I am sticking with Chrome

Talking about the tweet that got popular, there was in particular one user, @architex63, who had some radical opinions about another well meaning person who suggested that you might want to use StartPage Search if you want Google’s accuracy minus the Google’s tracking.

@marianstiehler @StartPageSearch @_icyflame @duckduckgo people in the know, know. I know a few of those people. I just try to warn people. can't really say why. do some research. good luck!

— Beeve Stannon (@architex63) May 11, 2017

I tried using classic.startpage.com and while the search results were accurate, the first three results were injected ads! They look exactly like the results and weren’t blocked by ublock. While ads are slightly annoying... Read More

Day 82 - A tweet that blew up

I tweeted something that quickly became my most liked and retweeted tweet.

twitter-screenshot

Surprisingly, I went to the myactivity page because of a button on the DDG search results page that pointed me to a DDG article about privacy measures to take on PCs and Android phones.

As someone quickly pointed out, I didn’t have Google Analytics or other analytics JavaScript running on the client side blocked. I used to use Ghostery for this. They gave a list of the tracking services which are installed on the sites you visit.

An earlier version used to show a list of the trackers and it wouldn’t go away immediately. I don’t think they even had the functionality... Read More

Day 81 - MISSED; Catching up on writing; Books

In perhaps the largest backlog of mine in this series of posts, I am now four posts behind. This post should have been out on 9th May, 2017.

I must run a test about how many times I spoke about this series in a post. I think it must be every other post. I am not even kidding. I am also at a position where I mut write the posts for the next 4 days.

I have moved slightly forward in Heather Poole’s book. Her mother becomes an air hostess and starts working alongside her! That is probably one of the weirder plot points in the book. The back stories and the way her roommates live their lives is rather... Read More