HNHacker News
TopNewBestAskShowJobs

justusw

910 karma · joined September 17, 2015

hello@justus.pw

My interests are: telecommunication, FOSS and decentralisation.

I run a consultancy in Tokyo focusing on software development and Open Source. I organise an online APL/J/K user group on meetup.com

Hire me!

[ my public key: https://keybase.io/justuswilhelm; my proof: https://keybase.io/justuswilhelm/sigs/r0imUgdXz-DJc7f1qbGQXhEzdeNEXSqVKXYWvcPm1j8 ]

submissionscomments
justusw··on ICQ: 20 Years Is No Limit
Most versions of Skype use SQLite for local storage, if that is of any help!
justusw··on A small dive into, and rejection of, Elm
The lack of introspection for union types during compile time has created some frustration for me as well. Not having some kind of compile time union list available sucks (it would probably be possible using some LISP-esque macro system), but I will gladly accept it, given the runtime safety.

I would like to encourage the author to revisit the 'timeRangeFromString' function and consider wrapping the result in a Maybe or Result, as this is exactly the type of function that is not guaranteed to deliver a result. With strongly typed languages like Elm it is best to use the type system to one's advantage, and not fight against it.

That is not to say that everyone should like Elm or similar languages, but they require you to shift the way you think about how you structure types.

justusw··on JSCity – An implementation of the Code City metaphor for visualizing source code
Fascinating. I wonder how easy it is to understand cohesion and coupling just by looking at these visualisations.
justusw··on When Big O Fools You
This article points out a few right things, but also skips over the wrong parts.

Namely, the amortised time complexity of dynamic lists.

Amortised analysis treats operations not as single events but looks at the time complexity over the span of many operations (through something called "Accounting"). An initial "investment" of array over-allocation will be amortised by inserting, but only over time. Inserting into an ArrayList will be in O(1) given enough insert operations.

Essentially, you over-allocate in order to save time. You're trading time complexity for space complexity.

A really good explanation on amortised analysis can be found here on Wikipedia, which explicitly treats ArrayList:

https://en.wikipedia.org/wiki/Amortized_analysis#Dynamic_Arr...

As always, a look into the source code of your language of choice helps. In Python, a list object over-allocates using a very peculiar, but finely tuned formula: https://github.com/python/cpython/blob/09dc3ec1713c677f71ba7...

justusw··on Higher-kinded types: the difference between giving up and moving forward
Interesting article and funny to see the shout out to Elm. I think the first few code samples made it very clear that Elm is missing something, at least for this type of generic programming, namely higher order types. Too many times I had to re-implement something that could have been solved in a generic fashion. Kind of similar to how Go programmers have to reimplement instead of generalise.

It is actively discussed in the Elm community (https://github.com/elm-lang/elm-compiler/issues/1039), but with a Wait-And-See-Approach. In my opinion, this is really laudable, as it signals readiness to add higher order types, and at the same time keeps developer friendliness of the resulting feature extension in mind.

justusw··on How Long Should I Make My API Key?
Comparing UUIDs is cheap, but avoiding non-constant-time compares is a necessity. So the usual for loop with an early exit when two bytes don't match up is poison. A web application could become susceptible to timing attacks.

This is a good article that helped me understand and mitigate the vulnerability: https://codahale.com/a-lesson-in-timing-attacks/

justusw··on How Long Should I Make My API Key?
For those who are not sure about the difference UUID vs. GUID

UUID = Universally Unique Identifier, RFC 4122 (https://tools.ietf.org/html/rfc4122.html)

GUID = Globally Unique Identifier, the (mostly) Microsoft flavored version of UUIDs, used in partition tables as well

Both of them consist of 128 bits, and both use 6 bits to denote the way the ID was generated, e.g. using the NIC MAC or timestamps.

An overview over the different RFC 4122 UUID flavors can be found here: https://en.wikipedia.org/wiki/Universally_unique_identifier#...

justusw··on How Long Should I Make My API Key?
Most programming languages do not use secure random number generators. As you suggested it is not always wise to use UUIDs for API keys if you are not sure about the nature of the PRNG.

Python for example uses os.urandom for random UUID generation (uuid4), as can be seen in the source: https://github.com/python/cpython/blob/3.5/Lib/uuid.py#L603

The standard library guarantees that os.urandom is "[...] suitable for cryptographic use." (https://docs.python.org/3.5/library/os.html#os.urandom)

I'm not sure about other languages, so it might always be a good idea to look it up in the source code.

justusw··on Emperor Akihito of Japan Raises Possibility of Leaving Throne
Even better: There is even some Korean ancestry mixed into the genetic stew (https://www.theguardian.com/world/2001/dec/28/japan.worlddis...)

Luckily, the state-worship of the emperor as a descendant of Amaterasu and Jimmu has been abolished after Hirohito declined being divine after WWII. Maybe now is a good time to take this one step further and to abolish the monarchy once and for all?

justusw··on Prolog.c: a simple Prolog interpreter written in 200 LOC of C++ (2000)
Using DCGs (https://en.wikipedia.org/wiki/Definite_clause_grammar), you can easily create grammars for automated document parsing and generation.

You could even write a compiler (http://comjnl.oxfordjournals.org/content/34/1/64.full.pdf) or disassembler (http://www.dtic.mil/dtic/tr/fulltext/u2/a242987.pdf) in Prolog fairly easy. All thanks to the really smooth support of tree-like structures.

I do wonder why all this seems to be a little forgotten. Granted, the syntax and semantics are a bit unusual, but the expressive power can hardly be matched.

justusw··on USB 3.0 Radio Frequency Interference on 2.4 GHz Devices (2012)
I'm glad to see that problems with Anker USB 3.0 Hubs happen not only for me. In my case, the Wifi became unusable once the Hub was connected. Quite a shame for a nice looking, affordable device to have a breaking issue with shielding.
justusw··on Blind-tested soloists unable to tell Stradivarius from modern violins
There is a great episode on Planet Money about Strads and other objects that have a high perceived value due to the history and branding that come with them.

They cite the same 2012 Indianapolis study mentioned in this article. The researchers have an amazing eye for detail. A perfume was applied to all violin's chin rests so that musicians would not be able to tell them apart based on smell. Tells you a lot about brand perception using all our senses.

This is the Planet Money episode: http://www.npr.org/sections/money/2016/06/22/482936331/episo...

justusw··on Squirrel Programming Language
Given that Lua and Squirrel are quite similar due to meta tables resembling each other, what does Squirrel provide compared to Lua except for the C-Style syntax?
justusw··on How to use Elm at work
That is the guide that helped me start, but is a long way to go until your first elm-only app. IMO the biggest weakness in the elm package ecosphere is that there is no proper solution to do url routing.

While elm-lang/navigation and evancz/url-parser get you 80% there, the remaining 20% cause a lot of pain.

I am very optimistic that in the coming months this situation is going to improve tremendously. If we all share more knowledge, tutorials, guides, the whole community will win!

justusw··on Show HN: AutoMicroFarm Is Ready for Shipping
That looks like an amazing concept! I especially dig the wading pool improvisation.

Ideally I would like to have something like this for indoors. Are there any plans to offer a non-backyard version at some point in the future?

justusw··on Escher: An Elm-like web framework for Julia
This could be useful for creating notebooks without using Jupyter. If it works, that is. I'm only seeing a blank page.
justusw··on Critical Update on DAO Vulnerability
I share your bitterness.

The meaning of the word "safe" seems to vary from person to person. The ETH and contract devs think safe means having a static PL to capture contracts.

But in reality it is safe as in, whoever exploited the vulnerability now has a "safe" source of income in a few weeks.

Perhaps it is a lesson better learnt now than later when the stakes are even higher.

justusw··on Critical Update on DAO Vulnerability
You're right, this can't happen every time.

If users truly want to embrace the decentralization then I see issues with the Ethereum maintainers doing very centralized and specific fixes to solve individual problems.

DAO != ETH, but I see how this is an act of self-preservation due to the amount of stakes the maintainers have themselves in ETH.

justusw··on Ask HN: What are some interesting, less known APIs?
Not sure what you mean by not mainstream :P, but here are some artisanal APIs that I like and have found on the Mashape market place (https://market.mashape.com/explore?query=).

- mSend, send SMS, https://market.mashape.com/webaroo/msend

- Have I been pwned?, https://market.mashape.com/troyhunt/have-i-been-pwned

- (inofficial) Whatsapp API, https://market.mashape.com/datayuge/whatsapp

justusw··on NoScript is harmful and promotes Malware
Any good alternatives for NoScript?
justusw··on Vim 8.0 is coming
> Is there a way how I can copy blocks of code outside the vim window to another application without also copying the line numbers?

If you're running vim in a terminal, there is an option to add native clipboard support to your yank registers. If you use vim under OS X and have installed it with brew, it will be added automatically. To check whether your current vim installation has clipboard support, try running `vim --version | grep +clipboard`.

You might also find this to be helpful: http://vimcasts.org/blog/2013/11/getting-vim-with-clipboard-...

justusw··on Namecheap live chat social engineering leads to loss of 2 VPS
What legal consequences could there be for Namecheap, if any at all?
justusw··on The Art of Tidying Up
Somehow, I am surprised that my comment seems to raise so many issues for you. That was not my intention. Like you, I don't view minimalism as this 'you're either a consumer or a minimalist' dichotomy that you perceive it to be. In the end it is just another tool in the toolbox. A tool that just happens to work for a lot of people that I personally know.

Consumption adds a lot of value to my life. Buying a washing machine buys me time which I can invest in other things I care about.

justusw··on The Art of Tidying Up
I am all for tidying up. One should not forget though, that there are many reasons for why things end up the way they do (as in, cluttered and untidy). I don't think that it 'just happens' that your house fills itself with things that you never will use. Sure, we can blame consumer culture and capitalistic indoctrination. But if we're honest, most of the stuff that we buy is because we hope that it will change us as a person and that we can fill that emptiness that lingers inside.

In the end, buying will not change lives as much as we think. Change has to come from within and from connecting with others. I really doubt that "300,000 things" will achieve that change.

I think the authors of http://www.theminimalists.com have some great answers regarding the question "if not consumerism, what will add value to my life?". While most of you already know the answer "friends, health, passion, etc.", and are tired of the platitudes, I am sure that it is easy to forget the values in a world surrounded by messages of consumption. If you are interested, I would recommend starting with this article http://www.theminimalists.com/21days/ about how the authors Joshua Fields Millburn & Ryan Nicodemus got started on their journey to minimalism.

justusw··on The benefits of static typing without static typing in Python
Do you mean decorators? A solution like that exists and has been used for a while. It really is only usable for run-time type-checks. See here: https://github.com/dobarkod/typedecorator

With type annotations you can have static guarantees, which decorators will not be able to provide, as decorator methods will be called and resolved only during runtime. Objects imported from `types` hopefully will not.

justusw··on Why I Taught Myself to Procrastinate
Very interesting. Especially regarding the starting a task, e.g. writing a sentence, and stopping midway only to return a day later. It resonates with me.

I think an important distinction in procrastination, that was not explored in this article, is that a task has to be started or at least prepared in order to successfully procrastinate upon it. For example, it won't help to put off finishing a university assignment until the last minute if you haven't read the task description. In that case, the thought processes that were mentioned in the article would never have a chance to start. On the other hand, if you have read a task description, even if you are procrastinating while binge-watching Netflix, a background process is still running and working on the task. The author of this article describes it as "Our first ideas, after all, are usually our most conventional" vs "When you procrastinate, you’re more likely to let your mind wander."

This ties in with a work methodology that works for me very well. Instead of working on a project non-stop as soon as it starts, I prefer to work in small chunks that give me enough time to "background-process" the task at hand while I'm not working on the given task. It is similar to practicing or physical exercise, in that the time that you spend on the activity is as important as the time that you are not spending on the activity. Your brain and muscles need time to regenerate and help strengthen the abilities that you are trying to nurture.

justusw··on Netflix Is Now Available Around the World
If I remember correctly, it was the same in Mexico and Scandinavia and some other countries. While there are ways to disable the subtitles through unofficial means, I doubt that they still work.

It is quite possible that this is due to licensing issues. This link here https://mrgnome.wordpress.com/2013/11/02/no-option-to-turn-o... might or might not help you, given its age.

In some sense it is still better than Amazon Prime in Germany with only German audio being available when I was using it last.

Do you know whether the same thing happens with Netflix original content as well?

justusw··on The Disappearance of Self in Japan
Thank you a lot for the nice response and the kind explanation. You are definitely right that there are never any bad intentions behind the various experiences that can be had as a foreigner.

Perhaps my problem is not really the experience itself, but that I don't know how to deal with certain situations in a smooth and sociable way. I also have not lived in Japan long enough to really master all social interactions. It's quite easy to forget when you're from another culture how much routine your own culture already has and how different it can be.

So, stage4目指せ!

justusw··on The Disappearance of Self in Japan
I can give you some examples for what can be described as micro-aggression (even if SJWs are totally abusing this term and take away any legitimacy when claiming to be a victim of it) Keep in mind that either of these things happen to me on a daily basis.

1) I speak JLPT ~N2 level with almost no accent, but get handed the English menu in a restaurant in Tokyo.

2) I get complimented for being able to eat various Japanese things (natto, umeboshi) or being able to handle chopsticks.

3) I get compliments for being able to read Kanji after talking to someone for the past few hours. How do they think I learned the language? With romaji?

4) Speaking to staff in Japanese, staff answers to my Japanese friends instead of speaking with me.

The last three ones are almost symptomatic for 日本人論, where it is common to think that certain Japanese cultural habits or attributes cannot be mastered or understood by outsiders, thus it is necessary to point them out or try to compensate for them.

Some of these attributes are reasoned to exist because of biological differences (google Japanese Brain), others because of the 'rich' cultural heritage of Japan that was never tainted by other countries (as if China and Korea are not close to Japan...).

Don't take this as me being unhappy to be in Japan. I just wish that people were a bit more self-aware around here. The problem is just that there is not the necessary vocabulary around to address these problems. It's not as if 人種差別 is a popular subject.

justusw··on The Disappearance of Self in Japan
I think in the end 日本人論 is just another form of supremacy, in this case Japanese. Notice the contrast to American exceptionalism, where a reason for USA Number 1 is often not needed, whereas nihonjinron usually requires some reasoning as to why the Japanese language is superior, or why Japanese brains are better, or why Japanese culture is exceptional. It is a very self-conscious way of exceptionalism :)

To be honest, I'm quite sick of any cultural glorification from any country. But given how Japan never went through a cleansing after their fascism (unlike east/west-germany after '45 and '68) I can understand that there is not a lot of self-awareness in that regard.

In some sense the youth is trying to distance itself from the problematic past by becoming apathetic consumerists.

Every time one of these articles crop up, I feel that someone is viewing Japanese through some heavily rose tinted glasses.

← PreviousPage 8 of 9Next →