Better HN
topnewbestaskshowjobs
Log inSign up

zingermc

286 karma · joined Apr 12, 2014 (12y ago) · 121 submissions

Submissions

comment 5y ago · link · parent

Wow, does this apply to Covid tests?

comment 5y ago · link · parent

Don't feed the troll.

comment 5y ago · link · parent

If the messages are encrypted at rest on your phone, it seems reasonable to expect the same of backups on the server.

comment 5y ago · link · parent

Yes, at least for Levenshtein-style edits (substitution, insertion, deletion).

Although, I suppose a spell checker algorithm would be O(mnd) where d is the size of the dictionary, because it needs to compute O(mn) edit distance for each of the dictionary words.

comment 5y ago · link · parent

> Let me tell you folks. Writing spaghetti code with no separation of concerns and no version control is not exclusive to php

Yowza. If I can give you some unsolicited advice: get some kind of version control in place! Even if it's just a local git repo at first.

There were two things that made working in ColdFusion almost tolerable. (1) The place I worked started using an MVC framework before I left. I was pleasantly surprised by how much it improved the experience. (2) Transitioning to CFScript instead of CFML tags made a big difference as well.

But at the end of the day, it's still ColdFusion, and it drove me bonkers.

comment 5y ago · link · parent

Hilariously, ColdFusion strikes again. I should have used pound signs around the bad_memories variable. The above code would dump the string "bad_memories".

Corrected:

<cfdump var="#bad_memories#"/>

comment 5y ago · link · parent

<cfdump var="bad_memories"/>

comment 5y ago · link · parent

Reminds me of CRN++, the molecular programming language. https://arxiv.org/abs/1809.07430

comment 6y ago · link · parent

AFAIK it has nothing to do with physical disability. The word has a lot of meanings: https://en.wikipedia.org/wiki/Gimp

comment 6y ago · link · parent

There does appear to be ARM64 assembly in Go's crypto code, but perhaps it's suboptimal for M1. Or perhaps there's a build config issue, and the assembly isn't being used. Just my speculation, though. I haven't looked into it.

https://github.com/golang/go/blob/master/src/crypto/aes/asm_...

comment 6y ago · link · parent

I've definitely been the victim of my own git hubris.

Once, when leaving a job, I decided to copy all of my local WIP branches to the server.

I whipped out this fancy --mirror option I had just heard of:

  git push --mirror $remote
Surprise! All branches on the remote repo got wiped. My local refs replaced the refs on the remote.

Somehow I found the right commits floating around in the git ether. I was able to recreate the branches, but I had to recreate their names by reading the commit log.

Did I mention this happened on my way out the door from a job? In retrospect, I shouldn't have panicked so much -- there were daily backups -- but the sheer terror I felt has made me read the man pages really closely to this day.

comment 6y ago · link · parent

Yeah, sounds like an O(n) sort to me.

comment 6y ago · link · parent

Keep in mind the adage "you get what you measure". If you optimize for CTR, you are not necessarily optimizing for user satisfaction/loyalty.

Case in point: Netflix's auto-play feature used to drive me bonkers, so much that I would try other streaming services first. How could they think this feature was a good idea? The only plausible explanation I've heard is that they were optimizing for user engagement. Users click around more to prevent the video from auto playing.

comment 6y ago · link · parent

By "positive response", are you saying that human "from" names yield a higher click-through rate?

comment 6y ago · link · parent

void DocumentScribbler.scribble(String s)

comment 6y ago · link · parent

> So, I should never drive?

> The bad thing about it is I usually don't realize that I'm getting sleepy until after I've dozed off once.

I'm not trying to be rude, but this sounds reckless. You absolutely should not be driving while you have this issue. Also, consider that you may have a sleep disorder.

comment 6y ago · link · parent

Does the policy disallow Oxford commas?

comment 6y ago · link · parent

I'm hopeful it's a startup that sells only the tops of muffins.

comment 6y ago · link · parent

"Factor X may contribute to low cognitive function and cannabis use."

comment 6y ago · link · parent

I think you can click the compass to switch between these modes.

comment 6y ago · link · parent

Your comment made me dig in a little more. I was wrong, it is only fetching the current tab, although it wouldn't need more permissions to see all the tabs.

In popup.js[1]:

    chrome.tabs.query({active:true,currentWindow:true}, function(tabs){ ... })
These `active` and `currentWindow` parameters to query() [2] restrict the results to the current tab. If I remove those parameters and run in DevTools, I seem to get a full tab listing.

[1]: https://github.com/pinoceniccola/what-hn-says-webext/blob/ma...

[2]: https://developer.chrome.com/extensions/tabs#method-query

comment 6y ago · link · parent

I feel compelled to point out that this extension sends the URLs of all open tabs to algolia.com when you click the extension (at least on Chrome).

I would much prefer if it only looked up the current tab.

A more private design might fetch the top N results from algolia.com and only search through them locally.

That being said, this is cool! Thanks for sharing.

comment 6y ago · link · parent

The beautiful part is that they may have no idea which IP address corresponds to your email until you click a unique link in the phishing email (or load a tracking pixel?).

comment 6y ago · link · parent

Awesome! Unguessable auth is the answer. You could even have the server generate a uuid token and have the user paste it into the browser extension.

comment 6y ago · link · parent

To follow up: the solution is that the localhost server needs to make sure each API call is authorized (if you aren't already). This means there must be a login/setup step.

An API call can't be considered authorized just because it came from localhost :)

comment 6y ago · link · parent

Unfortunately, CORS isn't a magic bullet. Suppose a site named evil.example adds a script tag pointing to http://localhost:1234/promnesia.js and a victim loads evil.example. If your JS updates a DOM element with info from the database, evil.example's JS can read that DOM element and report it back to the server, without violating CORS.

comment 6y ago · link · parent

Does promnesia server run a local HTTP server? How do you prevent a website from slurping up the entire database?

comment 6y ago · link · parent

I read that sentence 10 times. Wow.

comment 6y ago · link · parent

Android, Maps, Chrome?

comment 6y ago · link · parent

The important thing is that the `x` number of years requirement is a function of the role, not of the applicant's age.
12345