Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
kortex
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
68 ms
·
931.
▲
by
kortex
4y ago
A TUI FFMPEG builder would be delicious. Just a terminal powered graphical interface that lets me manipulate options, and feedback validation, would make it so much easier to work with complex graphs.
932.
▲
by
kortex
4y ago
Many thanks! > if you telemetry isn't already packetized, you'll need to do that yourself. Converting your drone's telemetry into something that ffmpeg likes is generally non-trivial. Yes, this is exactly the non-trivial s
933.
▲
by
kortex
4y ago
The data has temporal component, yes. But how would I packetize it in the first place? I have the high-level concept that I need to take each of my data chunks and put them into some kind of timestamped container/page/atom and fee
934.
▲
by
kortex
4y ago
The dry-python lambda soup is awful, I totally agree there. That's just there mostly for demonstration purposes though. Generally you'd actually use the flow construct (monads) to compose methods. But `obj and obj.method()` really
935.
▲
by
kortex
4y ago
My understanding is that Borgs can be subclassed, you can modify the behavior, use descriptors (setters/getters), etc. You also avoid the `global` keyword. It's really not the most compelling reason. I recently found a cleaner way
936.
▲
by
kortex
4y ago
Question for the peanut gallery, because it's vaguely topical and I've spent hours researching problem to no avail. How can I mux arbitrary data streams into a container? Let's say I have a drone and I want to stream audio, v
937.
▲
by
kortex
4y ago
Dependency injection and lazy_property are excellent, I use those all the time. I've used visitor on occasion. The rest? Mostly meh, some are straight up bad.
938.
▲
by
kortex
4y ago
It's basically a global / hoist with a more ergonomic way of accessing the state. Instead of a get_global_state() style function, you just have the Borg constructor. Personally I'm a fan of dependency injection whenever possi
939.
▲
by
kortex
4y ago
Nullable (Optional[Foo] / Union[Foo, None]) and Maybe[Foo] are similar but not quite the same thing. The difference is quite subtle. Optional[Foo] is same as Foo | None, meaning you can operate on foo with Foo's methods, except th
940.
▲
by
kortex
4y ago
I was in the same spot when I met this brilliant hardware hacker at this hackerspace who had no formal EE degree but could design circuits in his sleep. "How do you do it?" "I read data sheets and a lot of wikipedia". I
941.
▲
by
kortex
4y ago
> sometimes the fastest code deliberately introduces coupling, hardware specific cache shenanigans or unreadable hand written asm and/or inlined SIMD. >> this is a perfect example of how simpler code should be preferred _by de
942.
▲
by
kortex
4y ago
We really goofed as a society on that one. "But humans have ten fingers!" Well, we actually have 8 3-segment fingers and 2 thumbs, meaning you can count a dozen on one hand, and a gross on two, using thumbs as a cursor. You can al
943.
▲
by
kortex
4y ago
Cost and availability. Cylinder filters tend to be way more expensive ($30-50 per, I've seen true HEPA cylinder ones "for allergy sufferers" aka medical space, >$130) than rectangular (a few bucks). Rectangular also comes
944.
▲
by
kortex
4y ago
> Perhaps, “token-based” pagination would be a better term? Let's do it. When I was first learning about it, I wondered how the concept related to database cursors, if at all. It's really just a pointer to the next item at its
945.
▲
by
kortex
4y ago
If you use ULIDs for IDs (sortable by time, millisecond resolution) and a tombstone field (nullable deleted_at is a good one) then you have a very stable collection that guarantees no new objects will be inserted/deleted before the wri
946.
▲
by
kortex
4y ago
The article mentions a virtual optical fence that cuts the beam if anything impinges, so no roast pigeon with this system. Anything which the beam could couple to, haze, smog, etc, would definitely reduce efficiency for sure.
947.
▲
by
kortex
4y ago
> I'm tired of venv, PYTHONPATH and OS package dependency issues. To both you and the peanut gallery. You should basically* never be using PYTHONPATH or OS packages. And there are several solutions to improve ergonomics of virtualen
948.
▲
by
kortex
4y ago
Despite its warts, Python's type system is at least comparable to Go, and better in several areas. The type inference works really well much of the time without any assistance, you can use tools like pyre to generate types for untyped
949.
▲
by
kortex
4y ago
> Python is a pretty terrible language to work with. That's just like, your opinion, man. > Tooling sucks. Not in my experience. Lot of tools could be better, but I would not say there is a lack of un-sucky tooling at this poin
950.
▲
by
kortex
4y ago
You mean statically typed? Python is already strongly typed. Try running it through mypy with all the strict options. If you can get it to 100% pass and don't try to "cheat" the system too much with dynamic casts, I think you
951.
▲
by
kortex
4y ago
Is it possible to just use ::ffff:0:0/96 to map them? e.g. ::ffff:7f00:0/104 maps to 127/8
952.
▲
by
kortex
4y ago
How does that solve anything? Any hardware is gonna try to route packets to the "original" x.x.x.x and completely ignore this option field.
953.
▲
by
kortex
4y ago
What in the actual eff. Anything except actually switching fully to ipv6, amirite? Trying to see the most charitable position here - is there an aspect in which redefining 127/8 to 127/16 across billions of devices is actually fea
954.
▲
by
kortex
4y ago
It's all about managing entropy. Less surprising means you can use fewer letters. More surprising means more letters. That shouldn't be too controversial. The part where it gets tricky is when a concept is widely used, but is a co
955.
▲
by
kortex
4y ago
Underground construction is really hard to do correctly. Partial earth bermed foundations as you mentioned are a good compromise, especially if the earth is built up. But even then, drainage and soil pressure are big engineering concerns. A
956.
▲
by
kortex
4y ago
That's more or less what PEP 659 tries to achieve, albeit without the flag. Given that nearly everything in Python is an Object and can be modified/patched at any time, this dynamic adaptation is probably as best as one can get,
957.
▲
by
kortex
4y ago
A big part is that Python uses reference counting GC. Java, Go, C# all use tracing GC. Py_INCREF and Py_DECREF are responsible for inc/decreasing the reference count, and are not atomic. The GIL ensures refcount safety by allowing only
958.
▲
by
kortex
4y ago
It needed to be done; there were several choices in python 1/2 holding the language back, that all but necessitated breaking changes. Mostly with string/bytes/unicode handling. And the non-breaking route would have been a lon
959.
▲
by
kortex
4y ago
I think python is finding the loosey-goosey dynamic everything makes for bad application scalability, both for maintainability but also performance. Python with types, on the other hand, is pretty great for catching bugs before runtime.
960.
▲
by
kortex
4y ago
He openly admitted to having (deprecated term) Asperger's syndrome on SNL.
More ›