Better HN
topnewbestaskshowjobs
Log inSign up

codesnik

1,035 karma · joined Mar 11, 2009 (17y ago) · 493 submissions

Submissions

comment 6mo ago · link · parent

I had the same problem in air travel industry. Our ticketing officers were never able to communicate how the ticket commission rules from our partners should be interpreted. I ended up adding a test framework, that allowed to add examples and counterexamples of existing flights to each rule, to verify that they are applied the way they'd assign commission by hand.

comment 6mo ago · link · parent

nowadays you can vibecode some half-ass headless browser automation using your email-password or even weird corporate sso.

comment 6mo ago · link · parent

but why solar system is so out of scale?

comment 6mo ago · link · parent

git's mental model is very, very small, if you care to learn it. Then all the commands and their "inconsistencies" start to make sense - they operate on the model almost without any magic, and not on whatever is user's intent (it can vary a lot)

comment 6mo ago · link · parent

contactless ATMs

comment 7mo ago · link · parent

I've tried to come up with the reason they don't do it, and thought MAYBE they were afraid people would put PINs for the cards there and they thought it's a bad idea. I wonder why I even tried to invent a good reason for them, designers could just lack perspective and do not care at all, even in apple.

comment 7mo ago · link · parent

good for you and your particular bank.

comment 7mo ago · link · parent

give me ability to write a damn whatever on the card. My bank provides USD, EUR and other currencies on different cards with exact same cover. Maddening.

I can imagine that we don't have this option just because people would put their PINs there, and maybe it's not exactly secure enough, but sprinkle some validation on top and we'd be ok.

comment 7mo ago · link · parent

which is much better than nothing, but is a fairly recent addition

comment 7mo ago · link · parent

huh, I've never thought to check my github id. I don't remember myself being an early adopter.

comment 7mo ago · link · parent

i think it is the other way around. Git is pretty simple internally, and its ui is just knobs and levers to reach into that simple reliable internal structure. This is why for some people it seems like a mess - they want button "do what I want" (and all people and their needs are different), and for other people it's clean - open the throttle, engine will rev.

comment 8mo ago · link · parent

huh. I just did what you describe above (on tahoma) and was able to tab into the list of bluetooth devices, no problem.

do you have "Settings > Keyboard > Keyboard navigation" on? I thought it is on by default, but apparently it isn't. Without it "tab" only jumps between text fields and checkboxes.

There's also an "Accessibility > Keyboard > Full keyboard access", which gives more controls.

comment 8mo ago · link · parent

strange. Some keyboard shortcuts in os x are kinda weird and not intuitive to linux or windows users, but they are there. It's totally possible to use mac without trackpad. even cmd+tab switcher has a lot of hidden (but googlable) things: while still holding cmd after initial cmd+tab, you can close apps with q, switch to other apps with tab and (cmd+)shift+tab or left/right arrows, show app windows with down, etc. There's also a cmd+` for switching between one app's windows. I still find that distinction weird from usability perspective, but it's not too hard to adapt to it.

comment 8mo ago · link · parent

yes they do. check ruby for example.

comment 8mo ago · link · parent

I wonder, why that kind of ambiguity or complexity even comes to your mind at all. Just because python is weird?

def foo(self, arg=expression):

could, and should work as if it was written like this (pseudocode)

def foo(self, arg?): if is_not_given(arg): arg=expression

if "expression" is a literal or a constructor, it'd be called right there and produce new object, if "expression" is a reference to an object in outer scope, it'd be still the same object.

it's a simple code transformation, very, very predictable behavior, and most languages with closures and default values for arguments do it this way. Except python.

comment 8mo ago · link · parent

you could just treat argument initialization as an executable expression which is called every time you call a function. If you have a=[], then it's a new [] every time. If a=MYLIST then it's a reference to the same MYLIST. Simple. And most sane languages do it this way, I really don't know why python has (and maintain) this quirk.

comment 8mo ago · link · parent

basically all object oriented languages work like that. You access a member; you call a method which changes that member; you expect that change is visible lower in the code, and there're no statically computable guarantees that particular member is not touched in the called method (which is potentially shadowed in a subclass). It's not dynamism, even c++ works the same, it's an inherent tax on OOP. All you can do is try to minimize cost of that additional dereference. I'm not even touching threads here.

now, functional languages don't have this problem at all.

comment 8mo ago · link · parent

it starts with a pretty common char, but almost never gets in the way to the point I forget it exists. Meanwhile docker -t uses ^P which I use all the time for history instead of arrow keys. It's possible to configure it, but it's not worth the hassle on servers. Really, really annoying.

comment 9mo ago · link · parent

how does dichromatism restricts flight license? no instrumental flights? no night flights? something about perceiving warning lights on some panels?

comment 9mo ago · link · parent

pcr amplifies all sequences, correct or wrong, no? and as I understand it, it works on short snippets the best.

comment 10mo ago · link · parent

it'd sound reasonable, if that ownership wasn't already overconsolidated. But who says people doing that are reasonable.

comment 10mo ago · link · parent

I was a kid without any PC anywhere in 40miles around me, had no idea that SCSI had to be terminated or anything. I don't remember any jumpers on the drive, though.

comment 10mo ago · link · parent

nope. it was in a 3.5" bay in my standard AT box, but it was smaller, on some massive rusty metal adapter. It looks like it was from some early apple powerbook.

I've got my computer second hand from some rural school accounting department in south of Russia, circa 1994. Who knows how it got there. And who got and wired SCSI adapter compatible with ISA bus in that box.

comment 10mo ago · link · parent

I've been 10-11 at the time, and half the games I had didn't have an obvious "quit" menu option. I hated pressing the hardware "reset" button because it meant waiting for a minute again, staring at the BIOS setup screen.

Every time I figured out a weird hidden keyboard combination to exit from yet another game was a happy day.

comment 10mo ago · link · parent

very much not on topic, but that reminded me: my first PC (286) miraculously had a 40MB 2.5" Apple-branded HDD connected via SCSI adapter. Who knows where it was sourced from. One weird thing was that it initialized on boot for about 40 seconds, displaying nothing. I've been really surprised later seeing how fast other PCs with ATA drives were to boot. I still wonder, and maybe someone has a clue why init was so long? Is it something inherent to SCSI?

comment 10mo ago · link · parent

it's just "gitflow" is unnecessary complex (for most applications). with rebase you can work more or less as with "patches" and a single master, like many projects did in 90x, just much more comfortably and securely.

comment 10mo ago · link · parent

whoa. well, if it really works for you. The thing is, git has practically zero "destructive" commands, you almost always (unless you called garbage collector aggressively) return to the previous state of anything committed to it. `git reflog` is a good starting point.

I think i've seen someone coded user-friendlier `git undo` front for it.

comment 10mo ago · link · parent

I learned Perl scripting client for one MUD back in 2000, and that led me to web development.

Just a month ago, I remembered one MUD I've been trying out since 2003. And found that it is still online, and my password still works. Very weird feeling to log in to something 22 years later. It was pretty advanced at the time, with 256 color support, IPv6, advanced encoding support, etc. https://cryosphere.org/

comment 10mo ago · link · parent

well, not only their software but also hardware resources they're renting, but I agree they don't.

comment 11mo ago · link · parent

this is what I don't understand, why is it useless? there're multiple variants, vaccination could create reaction to a different part of the virus, etc.
12345
17