HNHacker News
TopNewBestAskShowJobs

mshenfield

561 karma · joined November 29, 2014

submissionscomments
mshenfield··on Developers are building communities that act as their own miniature power grids
25k per unit, assuming the battery lasts 5 years, is uneconomically high at $5k/year per home.

A 100kw generator can produce enough power for 100 homes, costs ~$50k all in, and ~$1k per day in fuel costs to run during an outage. Assuming the generator also lasts 5 years, that's only $100/year per home, 50x less than the battery solution.

Batteries are for the foreseeable future way too expensive.

mshenfield··on Twitter was down
It's back
mshenfield··on Starbucks illegally fired US workers over union, judge rules
No. Companies just have to re-hire fired employees and pay lost wages and benefits. IMO Starbucks should pay a large punitive fine that gets split between the fired workers and the NLRB.
mshenfield··on Google to reduce workforce by 12k
I've never seen anyone directly make this case. Most people seem to want their colleagues (many of whom are friends) to keep their jobs more than they want the stock price to go up.
mshenfield··on Atom was archived today
I'm still not convinced VSCode is faster and better. My Atom setup was never slow, the only thing that wasn't instantaneous was code completion. For me, it felt like VSCode came out of nowhere and surpassed Atom for inexplicable reasons.
mshenfield··on Twitter’s mass layoffs have begun
Twitter won't die, but it won't make much of a profit either. Elon Musk will find another buyer in 2 years for $25 billion and make most of his money back while leaving the company saddled with most of the $11 billion in debt financing.
mshenfield··on Never trust a system that seems to be working
Also a good reminder why exceptions and optionals exist. Bonkers that "I didn't get a response" defaults to 0.
mshenfield··on Imagen: An AI system that creates photorealistic images from input text
I like Pixlr, I use pixlr.com/e. It's free and web based and has always worked well for me.

Did that happen recently? It says in Pixlr's site they're owned by INMAGINE.

mshenfield··on Imagen: An AI system that creates photorealistic images from input text
These tools are amazing for prototyping. I had an idea for a promotional poster, and seeing my idea just by writing it felt like magic. The generated image had too many artifacts to use, but gave me a guideline to follow when creating the real thing in Pixlr.

AI content generation (text, image, source code, video, music) will be a huge boon for prototyping where applied judiciously.

mshenfield··on Twenty years of my blog
I had the luck of getting to interact with Simon a little at my first real programmer job at Eventbrite. You would never know meeting him that he was one of the creators of Django, (and TIL querySelector!). He was infectiously curious and excited about programming in a way that bubbled over to most people he interacted with. He would also enthusiastically engage with what you were working on, even the beginner project I had at the time. I don't know him well, but my impression was not just of a great programmer, but a great colleague and an authentically positive person.

Congrats on twenty years!

mshenfield··on A Trail Tale
Love everything about this. The 6+ lawyers of parallax background really make it feel alive.

Is the background generative in some way, or is each layer in a loop?

mshenfield··on Sunsetting Atom
I used Atom for a long time after it was cool. I just loved the idea of an editor I could extend using the standard web tools and frameworks. Overall love this project, and still am a little miffed that VSCode ate their lunch. Best of luck on everything Nathan and the team do.
mshenfield··on Ask HN: Have you ever switched cloud?
Thanks for acknowledging how much harder this is when you use a cloud-specific feature. Modifying your codebase to migrate off some cloud specific service seems like it would be by far the hardest part of switching clouds.
mshenfield··on We replaced rental brokers with software and filled 200 vacant apartments
Even though this begins with a pitch for empowering tenants, the customers are the landlords. The value for landlords comes at the expense of tenants in several ways.

* It prevents tenants who don't meet income or other requirements from even looking at the unit.

* It makes tenants liable for noting damage as soon as they view a unit to avoid it being attributed to them, a daunting task.

* And it removes a face to face interaction that forces some accountability on landlords who don't provide a clean/cared for unit.

Notably absent is a mechanism for tenants to provide feedback to landlords on the listing. The Questions feature is helpful, but not designed for concerns/praise.

mshenfield··on Emoji Under the Hood
It's a post about emojis, but I feel like I understand Unicode better now?
mshenfield··on Google Removed ClearURLs Extension from Chrome Web Store
Does Google contact developers before taking down their extensions?
mshenfield··on 10 Years of Open-Source Visualization: Did I learn anything from D3.js?
I used d3.js for one of my first programming projects. I was grateful and impressed that almost every question on Stack Overflow was answered by Mike Bostock or Jason Davies.

I'm (a little) older and (a little) wiser, and know this kind of support is a huge amount of work. It sounds like "focus[ing] on learning and broadening your perspective" is what fueled all those answers I so appreciated.

mshenfield··on Many small queries are efficient in SQLite
One trick of `pragma journal_mode = WAL` is that even with synchronous normal, SQLite syncs when you close the last connection [1]. So re-using a connection is key to getting the full benefits if you're executing commands from a single thread/process.

[1] https://sqlite.com/wal.html#the_wal_file

mshenfield··on Software engineering topics I changed my mind on
This list is self-consciously blunt/rude (correlating programming practices with intelligence and sanity) and unaccountable ("who knows what I'll believe in a few more years"). It's an annoying combination. I imagine many reader will haughtily deploy these commandments against their colleagues.
mshenfield··on Rqlite: The lightweight, distributed relational database built on SQLite
Going from a local db to one over a network has at least one risk. The SQLite docs gives developers the okay to write "n+1" style queries (https://www.sqlite.org/np1queryprob.html). When the db is on the same file system as the application this pattern is fine. But as soon a you add a network call it becomes a potential bottleneck.
mshenfield··on Ask HN: What are decentralized Twitter alternatives?
There hasn't been a post with the words "twitter alternative" in 3 weeks [0]... but this probably has nothing to do with Twitter banning Donald Trump today.

[0] https://hn.algolia.com/?dateRange=all&page=0&prefix=true&que...

mshenfield··on The Conspiracy Theory Handbook
The opening and closing lines are "real conspiracies do exist". Because of that, I didn't feel like the article claims that "people in power never do wrong".
mshenfield··on Hotwire: HTML over the Wire
The downside is that this makes it really easy for developers to avoid making an actual API. The turbo frames _are_ the API. Great to bootstrap, but miserable if you ever want to implement a native mobile app (or any other client) on top of the same codebase.
mshenfield··on Blob Opera
I'd love to see the source code on this. At least part of it is a language compiled to WASM (e.g. https://gacembed.withgoogle.com/blob-opera/harmonizermodule....)
mshenfield··on Smoke has caused temperature forecasts to go crazy
Intellectually I understand the comparison (politically motivated destruction of businesses) but it's so tone deaf.

The scale and consequences of Nazi Brownshirts and Kristallnacht - 7k businesses destroyed, 30k Jewish men arrested, by a racist state that would eventually kill them - are incomparable to what's happening here in Seattle.

mshenfield··on Smoke has caused temperature forecasts to go crazy
Appreciate this perspective!

I feel like I'm indirectly supporting his politics by engaging with his weather content. I'm generating ad revenue as a reader. And I'm increasing the size of the platform he can claim, which he can leverage for books, speaking gigs, etc. to promote whatever views he deems important. It's easy for me to find another weather source.

mshenfield··on Smoke has caused temperature forecasts to go crazy
Cliff Mass spoiled himself for me with this asinine blog post comparing Seattle BLM protesters to brownshirts in Nazi Germany [0]. It feels icky to get behind someone who will use his platform to sling ridiculous accusations and accept no criticism [1].

It's a shame - his weather reporting is uniquely good and fun to read.

[0] https://cliffmass.blogspot.com/2020/08/seattle-city-in-fear-...

[1] https://cliffmass.blogspot.com/2020/08/my-firing-at-knkx.htm...

EDIT: Fleshed out criticism of the original blog post:

http://www.dailyuw.com/news/article_8421ecd2-d90c-11ea-9e91-...

mshenfield··on Ways to make a web component
Thanks for clarifying! That's a fair point about web components having the capacity to be statically rendered and re-hydrated.
mshenfield··on Ways to make a web component
First contentful paint (FCP) is basically the same (+-10ms) from React down to a raw HTMLElement. I guess at some point appending elements to the DOM is the bottleneck, rather than the overhead of parsing JS and the efficiency of said JS.

To get a faster FCP, statically rendering the component to HTML and re-hydrating it in the client (using Gatsby, for example) seems like it will have a bigger impact than the WebComponent library used. Unless the client is bandwidth constrained of course.

mshenfield··on Brython – A Python 3 implementation for client-side web programming
I've looked into Brython and other "Python in the browser" implementations (transcrypt.org, pypyjs.org). It's fun! At a high level, the approaches are:

* Create a Python interpreter that is able to run Python code directly in the browser (PyPy.js, Brython)

* Transpile Python code into JavaScript and send that to the browser (Transcrypt, which also does a lot of tree shaking to keep the transpiled code efficient).

Here are the benefits, IMHO:

* Share helper code and class definitions across environments

* Most of the std lib, and a handful of popular 3rd party libs, are supported

* In the rare happy path, only have to think about one programming language.

The downsides are:

* Slow. For the "send an interpreter" approach (Brython, PyPy.js), the browser has to compile a whole compiler before moving on to running your code.

* Incompatibilities. For Brython and Transcrypt, C parts of the standard lib have to be re-written in Python for compatibility. So when you're importing something from the itertools package, it's actually a custom implementation like this: https://github.com/brython-dev/brython/blob/master/www/src/L.... The custom code will not always be exactly compatible with the CPython implementation.

* Incompleteness. Some std libs aren't implemented, or are only partially implemented. 3rd party libs that rely on these will not work. Popular 3rd party libs like sklearn which get their power by wrapping C/Fortran libraries need custom wrappers that don't exist (AFAIK) yet.

* You still gotta JavaScript. Even in the best transpilation scenarios, things break and you have to figure out what the generated or interpreted code is doing. This is especially tough for Python in the browser tools, which aren't widely used, so have both undiscovered bugs and a lack of community support. In my experience, working in a transpiled codebase doesn't mean you have to learn one thing, but three: the source language, the target language, and the frankenstein monster of the logic/compromises bridging the two.

* Tooling. The ecosystem hasn't reached a critical mass to support tooling. It's unclear if there's enough excitement in the Python community to get it there.

With all that said, unless you're a true believer or just want to have a little fun (again, it is fun!), I wouldn't recommend this.

Page 1 of 6Next →