Plutus, Haskell, Nix, Purescript, Swift/Kotlin. laser-focused on FP: formality, purity, and totality; repulsed by pragmatic, unsafe, “move fast and break things” approaches
AC24 1DE5 AE92 3B37 E584 02BA AAF9 795E 393B 4DA0
It feels like magic. I think of it as the glue that makes almost all of my software work together seamlessly. I can’t wait to use it for one-click deployments of my software on a server or high-availability cluster.
This is why I decided to learn Nix. I built dev environment flakes that provision the devshell for any language I intend to use. I actually won’t even bother unless I can get something working reliably with Nix. ;)
For example, here’s a flake that I use for my Python dev environment to provide all needed wiring and setup for an interactive Python web scraper I built:
{
description = "Interactive Web Scraper";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs?ref=nixpkgs-unstable";
utils.url = "github:numtide/flake-utils";
};
outputs = { self, nixpkgs, utils }: utils.lib.eachSystem ["x86_64-linux"] (system: let
pkgs = import nixpkgs { system = system; };
in rec {
packages = {
pyinputplus = pkgs.python3Packages.buildPythonPackage rec {
pname = "pyinputplus";
version = "0.2.12";
src = pkgs.fetchPypi {
inherit pname version;
sha256 = "sha256-YOUR_SHA256_HASH_HERE";
};
};
pythonEnv =
pkgs.python3.withPackages (ps: with ps; [ webdriver-manager openpyxl pandas requests beautifulsoup4 websocket-client selenium packages.pyinputplus ]);
};
devShell = pkgs.mkShell {
buildInputs = [
pkgs.chromium
pkgs.undetected-chromedriver
packages.pythonEnv
];
shellHook = ''
export PATH=${pkgs.chromium}/bin:${pkgs.undetected-chromedriver}/bin:$PATH
'';
};
});
}
I’d absolutely adore those guitars if they weren’t so damned heavy. I can’t imagine building off-cut versions will alleviate that complaint.
Threads used to bewilder me until I started using Haskell. Holy shit that felt like magic, turning an app parallel with two lines of code.
Now, I just have to worry about memory limits….
Removed by mod
Removed by mod
“I” seem to require? No. I’m deferring to the cypherpunk manifesto which rings true over and over again.
IMO, anonymity should be able to be switched on and off at will by the user. Selective disclosure using homomorphic encryption coupled with digital identity can achieve both, IMO.
In particular, businesses require anonymity in much of their chain of custody…and I think that’s fair.
Perhaps. I tend to listen to Snowden when it comes to tech. But I haven’t used it yet because all of the implementations I could use involved a bitcoin wallet. I’m a fan of crypto but that felt weird.
Someone else reassured me that NOSTR is a very open platform and that requirement wasn’t true.
From my research, I have found it to be far more decentralized than Lemmy’s (and the pub/sub) federated model, which would also, obviously have the same drawbacks that we see in other truly decentralized tech like crypto, torrents, and tor where you are on your own in the world, forced to literally keep the ocean of shit from infecting you! 😉
So, I think of those things as necessary evils. For example, if I used NOSTR, I could have an address that follows me no matter what. That cryptographic hash is my NOSTR identity for better or worse. That’s pretty powerful and far more secure than a two step verification process in the long run.
I don’t know enough about it yet. But I’d say it is a raw technology that I wouldn’t allow the criminals and trolls of the world define for me.
Are the people who invented this aware of NOSTR?
If so, what makes this different? And if not, perhaps we could use NOSTR to bridge the gap in the fediverse at the moment between NOSTR users and Mastodon/Pixelfed/Lemmy/KBIN/MBIN users
I started forking Lemmy for an inventory system but then realized that NOSTR was far more suited to that and other applications that require security and encryption.
You fucking rock! Thank you!
I’m no geologist but I’d have said slate.
So, I looked it up and the description of Phyllite seems on point. Geology is super interesting!
Even more searching showed shale which also looks like a good candidate. Thanks for posting this. I have been curious about geology lately and this caused me to look this up.
Yes! I love Hackaday SO much. Now, I can just get it here. Subscribed.
Interesting perspective. Thanks for elaborating. You twisted my original concept in knots and won me over to your read of it.
I posted this meme in three places. Did you not read any of the threads where old, cranky FHS luddites came out of the woodwork to angrily dismiss the concept of immutable distros?
Duly noted. I DO NOT use Arch, btw. ;)
What I meant to try and say is that GUIX is like NixOS for Chad programmers.
I’d look into building all of that in a flake just so you can encapsulate (and have a central version control of) all of your dependencies in case something does change.
I’m a bit of a Nix dork but I tend to try and declare my entire dev stack in a flake so it can follow me to every machine. It offers some of the “it works on every machine” guarantees that Docker offers while also forcing the compilation of the stack to happen natively (or at least pulls in some content addressed cache that offers security by being the exact hash for the whole dependency graph). I like that
Here’s how I used the Nix way to declare an interactive Python scraper the other day. With this method, I can lock dependencies between machines as a matter of course without having to use Docker:
{
description = “Weed Scraper”;
inputs = {
nixpkgs.url = “github:NixOS/nixpkgs?ref=nixpkgs-unstable”;
utils.url = “github:numtide/flake-utils”;
};
outputs = { self, nixpkgs, utils }: utils.lib.eachSystem [“x86_64-linux”] (system: let
pkgs = import nixpkgs { system = system; };
in rec {
packages = {
pythonEnv =
pkgs.python3.withPackages (ps: with ps; [ webdriver-manager openpyxl pandas requests beautifulsoup4 websocket-client selenium keyboard ]);
};
devShell = pkgs.mkShell {
buildInputs = [
pkgs.chromium
pkgs.undetected-chromedriver
packages.pythonEnv
];
shellHook = ‘’
export PATH=${pkgs.chromium}/bin:${pkgs.undetected-chromedriver}/bin:$PATH
‘’;
};
});
}
Yeah. I think they’ll catch on in much the same way that lock files have become the standard in many languages. IMO, it just makes more sense to declare all dependencies atomically. I also think/hope it will supplant our overreliance on Docker containers to achieve these kinds of guarantees (where it actually makes sense or presents undeniable benefits).
This person gets it.
I’ve been thinking a lot about this. Another way might be for a Lemmy instance to run a stake pool from the same machine. They could offer perks to users while also not requiring donations directly. Perhaps even reward users with the pool’s native tokens for every post they submit or something (this is a great place to bring up the drawbacks and very real issues that offering a perverse incentive can have: Cobra Effect).
The tech chosen is a key decision(in this case Cardano would be my recommendation honestly because I prefer the tech and not because I have a bag of it) because that stake pool could mint native tokens and use those as a currency for use on their instance if we used Cardano. Native tokens on Cardano are cheaper and not subject to the same fees as other (ERC-20) chains to use and mint. So it would allow that instance to have its own native currency with very little overhead.
Look at Kbin’s old code. There’s some mention of Cardano wallets on there so I’m guessing that the creator of that was interested in this idea.