Readit News logoReadit News
ktm8 commented on Python Best Practices for a New Project in 2021   mitelman.engineering/blog... · Posted by u/jedwhite
wwwhizz · 5 years ago
"best practices"

`curl https://pyenv.run | bash`

hmmm...

ktm8 · 5 years ago
The script itself is also a wrapper for curl | bash
ktm8 commented on I spent 5 years writing my own operating system   github.com/halfer53/winix... · Posted by u/halfer53
ktm8 · 5 years ago
I'm mildly annoyed by line 30 in include/posix_include/stdio.h
ktm8 commented on “Older unlisted videos will be made private unless you opt out”   support.google.com/youtub... · Posted by u/tech234a
quantumofalpha · 5 years ago
Yes, exactly. Video ID is just a base64'ed DES-encrypted primary int64 video key from MySQL. It used to be sequentially incremented until at some point they switched to randomly generated primary keys. Any (ex-) engineer who snapped a copy of the encryption key (it used to sit right in the code for anyone to see) can enumerate all videos from YT until that moment, including unlisted - which are only protected by secrecy of that one key. If the key leaks, then also anyone in the world can. That's what they are afraid of here. Source: worked for YT.
ktm8 · 5 years ago
Just for curiosity, how would YT deal with ID collision ?

Edit: Before the scheme change I mean

ktm8 commented on You can legally get and run WordPerfect for free   liam-on-linux.livejournal... · Posted by u/lproven
ktm8 · 5 years ago
Unrelated, but that website ruins the back history for me. So annoying.
ktm8 commented on Yatima: A programming language for the decentralized web   github.com/yatima-inc/yat... · Posted by u/agentofuser
jcburnham · 5 years ago
So, I love Rust immensely, but it's a totally different style of programming than a functional language like Haskell. For example, Rust closures are absolutely not the same as pure functions, and if you try to use them that way you'll have a bad time. Another thing is that Rust's approach to garbage collection is "opt-in" (with Rc, etc), which is great for low-level control, but not so great when you're trying to write high-level or non-performance-critical things. And lastly, recursion is Rust is restricted by the stack, so if you try to recurse too much you'll panic. You can manually increase the stack, of course, but this is again a case of having to explicitly handle your resources.

In some sense, Yatima's trying to be to Rust what Haskell is to C. We reuse a lot of the primitives (like ints, uints, chars, etc), but in a separate runtime layer that lets you just use a lambda like a lambda, and not have to worry if you're recursing too much. Now, that comes with overhead, but in a lot of places (like on the web) that's acceptable.

Another thing to think about is determinism. One goal of Yatima is to have each content-id always run the same way given the same inputs. That means we have to forgo using things like hardware floats (or at least not without some complex wrapping) which can cause UB if you try to read their bits (even in WASM).

I think definitely we're going to want to explore both frontend (along the lines of something like https://seed-rs.org/) and backend use cases for Yatima. I'm looking with great interest at https://github.com/lunatic-solutions/lunatic to see if there's a way for us to integrate their lightweight processes. As far as I understand this is along the lines of what https://www.unisonweb.org/ is doing.

The other thing I'm thinking about is smart contracts. Since Yatima is almost `no_std`, we should be able to build it as a pallet for substrate.dev.

ktm8 · 5 years ago
> In some sense, Yatima's trying to be to Rust what Haskell is to C

Can someone explain to me how C and Haskell are related here ?

u/ktm8

KarmaCake day27June 3, 2021View Original