Monday, April 16, 2018

TWID April 16, 2018

This is a post detailing some stuff I did, learned, posted and tweeted this week, I call this TWID (This week in Denis). I am doing this mostly for myself... a kind of an online journal so that I can look back on this later on. Will use the label TWID for these


This Week I Learned

Finished the Understanding Machine Learning with Python Pluralsight course

Understanding Machine Learning with Python


This was a pretty interesting course and it's perfect for a beginner. You don't need to know any AI, you also don't need to know much Python either


This Week I tweeted

Oops... connected to the wrong server


On Tuesday, 13 March 2018 at 12:04 UTC a database query was accidentally run against our production database which truncated all tables.

It took us a day to uncover the root cause of the original database truncation. Using our API logs, and with information from our upstream provider about the IP address the query originated from, we were able to identify a truncate query run during tests using the Database Cleaner gem. The shell the tests ran in unknowingly had a DATABASE_URL environment variable set as our production database. It was an old terminal window in a tmux session that had been used for inspecting production data many days before. The developer returned to this window and executed the test suite with the DATABASE_URL still set.

This is why getting to the production DB should only be enabled on a handful of servers, which few people can access. Deploy to prod from there, test, staging and dev can be done from less restrictive machines. Never should you build both from the same machines!


The sale of electric cars more than doubles in first quarter in the Netherlands

The sale of battery-powered electric cars increased by 136% to 3,945 in the first three months of 2018, motoring organisation RAI Vereniging reported on Monday. The market for electric cars, so far, is miniscule, but the Netherlands is the world’s fifth-largest market for electric cars after China, the US, Japan and Norway, according to the International Energy Agency.
It's still a small number in the grand scheme of things but it is promising. Wondering if the Tesla 3 model will make an impact.


Check if facebook shared your info with Cambridge Analytica

Recently, we shared information about the potential misuse of your Facebook data by apps and websites. We also shared plans for how we're taking action to prevent this from happening in the future.
Check below to see if your information may have been shared with Cambridge Analytica by the app “This Is Your Digital Life.”

It looks like my data wasn't shared.. but then again I don't take silly quizzes. I also don't have facebook installed on my current phone which I got in December, neither have I ever logged in from the PC I am typing from at the moment.



Why Does “=” Mean Assignment? 

A common FP critique of imperative programming goes like this: “How can a = a + 1? That’s like saying 1 = 2. Mutable assignment makes no sense.” This is a notation mismatch: “equals” should mean “equality”, when it really means “assign”. I agree with this criticism and think it’s bad notation. But I also know some languages don’t write a = a + 1, instead writing a := a + 1. Why isn’t that the norm?

The usual answer is “because of C”. But that’s just passing the buck: why does C do it that way? Let’s find out!

I also always though it's because of C  :-)  Now you know why :-)



A massive, 'semi-infinite' trove of rare-earth metals has been found in Japan

Researchers have found hundreds of years' worth of rare-earth materials underneath Japanese waters — enough to supply to the world on a "semi-infinite basis," according to a study published in Nature Publishing Group's Scientific Reports.
Rare-earth metals are crucial in the making of high-tech products such as electric vehicles and batteries, and most of the world has relied on China for almost all of its needs.

Japan started seeking its own rare-earth metals after China held back shipments in 2010 during a dispute over islands both countries claim. These island are the Senkaku Islands, they are also known as the Diaoyu Islands and the Pinnacle Islands



Unusual Homes Around the World

Some of these houses are very unique, strange and in some cases very impressive. The Heliodome one looks really interesting.

Would you want to live in some of these?

See also http://www.imdb.com/title/tt7804132/ for a documentary about unusual homes. I like the house that uses the wing of an airplane as its roof


Some cool stuff you might enjoy

DatabaseFlow -- an open source self-hosted SQL client

Database Flow is an open source self-hosted SQL client, GraphQL server, and charting application that works with your database. Visualize schemas, query plans, charts, and results. You can run Database Flow locally for your own use, or install to a shared server for the whole team.

Here are some screenshots of what it looks like



Electricity Map

This shows in real-time where your electricity comes from and how much CO2 was emitted to produce it.

You can see what it looks like here


Some pics I took

Found this Indian Head penny from 1900 in my change. As you can see it's pretty worn out and not worth more than 25 cents probably. But it's still a nice piece of history to have. I think the older US coins were much nicer looking that the current ones. The Morgan dollar coin is probably one of the best looking coins ever made.




No comments: