HNHacker News
TopNewBestAskShowJobs

hnov

382 karma · joined December 28, 2013

submissionscomments
hnov··on Tricking PostgreSQL into using an insane, but faster, query plan
In this case denormalizing the data right into the runs table would likely give you better, but more importantly more predictable performance.
hnov··on PayPal faces lawsuit for freezing customer accounts and funds
You can tell them, "dame la multa" (give me my fine) and most of the time they'll wave you on.
hnov··on The Tipping Point: The Economics of Taxi Fares
I personally don't care for the arbitrary nature of it. I want Uber to cost more so that people on the brink of financial ruin aren't trading equity in their vehicle for quick cash. I want my restaurant bill to include the cost of a living wage for the staff. I do "tip" my 20%, even when the service is absolute dogshit, because the waiter didn't overcook my food, and the kitchen staff didn't forget my order.
hnov··on Google no longer producing high quality search results in significant categories
Some of the WireCutter’s picks were fairly terrible, which makes sense: testing diverse categories of products is too expensive for affiliate links to cover. I’ve gifted dashcams on their recommendation that shot beautiful QHD but had MTBF measured in single digit months. The TP-Link C7 Archer was kind of a turd and within a stone’s throw of a decent router price-wise.
hnov··on Apple said to be preparing for iPhones without SIM card slot in 2022
Presumably this will be an inflection point for eSIM availability and you'll be able to add all 4 plans to your phone and switch to any 2 of them on the fly.
hnov··on Apple said to be preparing for iPhones without SIM card slot in 2022
FYI, iPhone 13 generation devices already have 2 eSIMs, as in you can have dual standby without a physical SIM. I'm not a fan of this direction but I don't think we're going to lose dual SIM support.
hnov··on Ruby vs. Python comes down to the for loop

  def proc &p
    p
  end
is what the special method looks like but yeah they’re not standalone expressions but rather part of the method call syntax.
hnov··on Ruby vs. Python comes down to the for loop
I think the crucial difference is that a block can control the flow of the enclosing frame, somewhat analogously to python context managers. For example

  def get_widget
    with_lock do
      return @widget # returns from the method call
    end
  end

  def update_interesting_gadget
    @gadgets.each do |g|
      g.with_lock do
        if g.is_theone?
          g.update
          break # breaks the enclosing each's while loop
        end
      end
    end
hnov··on Toyota spreads anti-EV propaganda in Japan
No, it's just sleight of hand. They take a study that states "EVs produce fewer _greenhouse emissions_ per mile than _diesels_ even on Poland's fossil fuel electrical grid" and turn that into "Even on dirty grids, EVs are cleaner".

1. Burning coal emits NOx, SO2 and other toxic and radioactive shit, which is not what the studies were about. For example an American city like LA emits a ton of CO2 but I wouldn't call it polluted compared to someplace like Shanghai where PM2.5 in the air poses a danger to your health some days. Greenhouse gas emissions and pollution are related but different.

2. Japan doesn't really use diesel for passenger vehicles and diesel tends to be pretty dirty in terms of NOx, especially diesels before dieselgate.

So the premise that on a dirty grid an EV is cleaner than an ICE car may or may not be true. Note that the study doesn't seem to be touching on hybrids at all which will obviously close to (non-hybrid) diesels in terms of CO2 while offering even lower toxic emissions.

hnov··on Toyota spreads anti-EV propaganda in Japan
Calls the opposing viewpoint "anti-EV propaganda", then states that "Even on dirty grids, EVs are cleaner" which links to an article titled "Even electric cars powered by the dirtiest electricity emit fewer emissions than diesel cars, says new study".
hnov··on Thank you, GitHub
Popping the stack so to speak before embarking on the next ____.
hnov··on Google's infamous internal 2010 “I just want to serve 5TB” video now public
This is paradoxically because historically everything was wide open to anyone so access-control and such isn't super fleshed out for most apps behind the proxy. Random internal app X could have been conceived and built with very little oversight and opening it up to a rotating cast of temporary workers is seen as an unnecessary risk. Broadly used apps (e.g. the bug ticket system) tend to have app-level security-controls and are not blocked by the proxy for contractors.
hnov··on Show HN: Print a WiFi Login Card
My iPhone has a pre-defined "Make QR Code" "Starter Shortcut" that you can invoke by typing "Make QR Code" in Home screen search. It basically generates a QR code of the same WIFI:S:$SSID;P:$PASSWORD;; format as wificard.io.

https://en.wikipedia.org/wiki/QR_code#Joining_a_Wi%E2%80%91F...

hnov··on What Does My Site Cost?
I've been traveling a lot and what I've done is setup an AT&T based MVNO on my iPhone's eSIM, freeing up the physical slot for local SIMs. With WiFi calling enabled on my AT&T line, I can go around the world spending peanuts compared even to Google Fi, while keeping my US number working.
hnov··on Every American Car Brand Is on the Bottom Half of CR's Reliability Rankings
A lot of E46 M3s are still running around with 200k on the clock despite having motors and chassis that chew themselves up. Same with the MK3 Supra and its headgaskets. IMO whether you still see cars around is as much a function of their value retention as it is of their robustness.
hnov··on Show HN: Edabit – Like Duolingo for Learning to Code
The way I learned Ruby 5 years ago was by doing Koans[0] which is basically a test suite where the individual cases describe some behavior of ruby or its stdlib and have a small expression missing to be filled in by you.

  array = [1, 2]
  array.reverse!
  assert array == __
[0] http://rubykoans.com/
hnov··on We saved $50k/year with a Go microservice coded in a hackathon
Elasticsearch works for this use-case quite well, you'd store a fairly straightforward representation of the MySQL row as a document, query by the fields you're interested in and ask for aggregations on the matching documents. Common bitsets get cached automatically.
hnov··on AMD's Hidden Strategy
AMP version without login required https://www.google.com/amp/s/seekingalpha.com/amp/article/41...
hnov··on Terraform Gotchas and How We Work Around Them
You pretty much have to take the same approach as you would outside of terraform: create the new thing (launch configuration, standalone instance) and attach it to the ELB before spinning down the old one. Terraform does have some rudimentary aid to that end in the form of the create_before_destroy[0] flag, though it doesn't work out with uniquely named things.

[0] https://www.terraform.io/docs/configuration/resources.html#c...

hnov··on Breaking a large AWS spend into understandable pieces
This is exactly what our team has been working on[0] for over a year now. Beyond running a simple, 2-3 component service on AWS, it's pretty hard to actually know what's going on with your billing. Tagging and cost allocation reports help, but you do quickly run into a wall with shared resources like segment did.

We don't yet introspect ECS clusters to assign a portion of spend to tasks, but we do breakdowns of services, tags, instances, ELBs etc across 1-N accounts. For S3 we can actually introspect buckets and produce rollups by object metadata as well as heat maps (which objects are being accessed a lot)

[0]https://trackit.io

hnov··on Httpie: A CLI http client
Starting with 3.5[0] that's the standard behavior.

One liner-wise, you could create an alias

  echo '{"foo":12, "bar": 11}' | python -c 'import json as j, collections as c, sys as s; j.dump(j.load(s.stdin, object_pairs_hook=c.OrderedDict), s.stdout, indent=4)'
[0] https://github.com/python/cpython/blob/3.5/Lib/json/tool.py#...
hnov··on How Arel Converts Ruby Queries into SQL Statements
More generally, the visitor pattern is an example of double dispatch, where the concrete implementation of a function varies on the type of two parameters to the function. I'm not sure that there's any real difference in the implementation of the visitor pattern that arises from static vs dynamic typing. Just like in ruby, in a language like java you could have a cascade of if/elses that type check the second parameter (or the first one for that matter, OO is really just a way to have a case statement that isn't centralized in one place in source code).
hnov··on Marijuana may be even safer than previously thought, researchers say
Empirically, driving under the influence of marijuana makes one safer by dialing back their willingness to take risk. Empirically, I'd rather be a passenger to stoner a than someone past their 60s, in their teens or recently emigrated from a non driving country. More research needs to be done before we can make any conclusions but research to date hasn't shown it to be a problem [0]. I actually dread legalization because it's only a matter of time before some legislator decides to "crack down" on the menace that is stoned drivers.

http://norml.org/library/item/marijuana-and-driving-a-review...

hnov··on Higgs JavaScript Virtual Machine
Could it be that this technique is not as broadly applicable as the existing JIT techniques? Would it be possible to use the approach taken with Higgs to implement a language with a more open ended object system such as ruby? In JavaScript there's an upper bound on what a + b could mean, does BBV work well for more general method dispatch?
← PreviousPage 5 of 5