@traumaphoenix@chaos.social
@traumaphoenix@chaos.social avatar

traumaphoenix

@traumaphoenix@chaos.social

transfem enby(s) and dissociative system of 12, please handle with care

feel free to follow, mostly a vibe check.

hobbies include but aren’t limited to: writing comfy software, photography (mostly birds, sometimes landscapes or architecture), other miscellaneous creative endeavors

photography is CC BY-NC 4.0, higher resolutions available on request

:disability_flag: :trans_flag: :nonbinary_flag: :anarchoheart1: ΘΔ

PSA: our avatar and first name is gonna change a lot (synced to PluralKit)

This profile is from a federated server and may be incomplete. Browse more on the original instance.

whitequark, to random
@whitequark@mastodon.social avatar

i did not realize how fragile "sd card plugged into raspberry pi" is. my headmate's 3d printer server just... had an sd card die. it sort of reads except sometimes it spends half a minute reading a single sector

wtf

traumaphoenix,
@traumaphoenix@chaos.social avatar

@whitequark sd cards are just the cheapest trash flash on the market, even the expensive ones

it's why professional gear usually has a backup slot 🦋

astrid, to random
@astrid@fedi.astrid.tech avatar

my laptop looks so wrong without stickers. like it doesn't feel right anymore. doesn't feel like mine. which tbf it won't be mine very soon

traumaphoenix,
@traumaphoenix@chaos.social avatar

@astrid honestly every laptop should just have a big magnetic panel that goes on top of the top case

then you can just buy another laptop and put the entire sticker plate back on 🦋

traumaphoenix, to random
@traumaphoenix@chaos.social avatar

it’s honestly kind of baffling discord has never been seriously slapped for GDPR noncompliance

here’s what deleting your account does:

  • it locks you out
  • it removes your avatar and username and profile content

here’s what it doesn’t do:

  • delete public or private messages
  • delete other people’s notes of you
  • make the API retroactively censor message metadata like user ID

so basically if you want things deleted, break TOS and do it yourself (you won’t get everything) 🦋

traumaphoenix,
@traumaphoenix@chaos.social avatar

@whitequark i get having a local chat backup, but remote data on a server you don’t control…?

that stuff is always at risk of disappearing, at the latest when the platform crashes and burns 🦋

scy, to python
@scy@chaos.social avatar

Imports in Python can be confusing.

I just saw someone ask "why do I have to prepend a dot to import a file in the same directory?"

That depends on whether the file with the import statement is in a package or not.

But, whether Python considers it to be in a package depends on how you imported (or ran) that file. You can't determine it from the file's content or the filesystem structure!

Check alt text (image description) for explanations of the examples.

Running four commands from the parent directory. "python3 mypkg/abs_import.py" prints "in pkg", because Python found mymod.py in the same directory as the file it has been asked to run. That's because sys.path (which is used to define search order for modules) is initialized like this (quoting from the docs): "The first entry in the module search path is the directory that contains the input script, if there is one. Otherwise, the first entry is the current directory, which is the case when executing the interactive shell, a -c command, or -m module." "python3 mypkg/rel_import.py" throws an ImportError: "attempted relative import with no known parent package". Just because you're running a file in a subdirectory doesn't make this directory a package. "python3 -m mypkg.rel_import" prints "in pkg", because Python is now interpreting mypkg as a package name, has found the rel_import module in that package, and is able to do relative imports from there. "python3 -m mypkg.abs_import" prints "top level". Remember the documentation from above: If there is no input script (and there isn't, we're asking Python to resolve and run a module instead), sys.path will first look in the current directory, i.e. the one containing the mypkg package, because that's the one we're currently in.
We now change into the mypkg directory with a "cd" command. "python3 abs_import.py" prints "in pkg", because Python is going to look for "mymod" in the directory containing the input script (which happens to be the current directory, but that's not relevant). "python3 rel_import.py" throws an ImportError "attempted relative import with no known parent package" again. Understandably, because Python has no way of knowing that the directory we're currently in can be interpreted as a package. "python3 -m abs_import" prints "in pkg", because sys.path first looks for mymod the current directory. "python3 -m rel_import" raises an ImportError "attempted relative import with no known parent package" again. That's because, in contrast to what we did in the last example in the previous screenshot, we're now just using "rel_import" as the module name we're asking Python to run, without the "mypkg" prefix. Adding the prefix wouldn't work, because our current directory is already inside the mypkg package and Python (correctly) wouldn't find another "mypkg" directory in it. But without the prefix, Python doesn't know that the "rel_import" module resides in a package at all.
We now move into the parent directory again ("cd ..") and delete the top-level mymod.py file. Then, we attempt the examples from the second image again. "python3 mypkg/abs_import.py" prints "in pkg" as before, because Python found mymod.py in the same directory as the file it has been asked to run. "python3 mypkg/rel_import.py" throws an ImportError: "attempted relative import with no known parent package", just like before, because it interprets the file path as a script to run, not as a module in a package. "python3 -m mypkg.rel_import" prints "in pkg", just like before, because Python is interpreting mypkg as a package name, has found the rel_import module in that package, and is able to do relative imports from there. "python3 -m mypkg.abs_import" throws a ModuleNotFoundError "no module named 'mymod'. Before, it printed "top level", but now we have deleted the top-level mymod.py file that it was importing.

traumaphoenix,
@traumaphoenix@chaos.social avatar

@scy and then you have packages importing other packages and people will do:

from your_package import magic_internal_code

because

your_package/init.py

from ._internal import magic_internal_code

🦋

traumaphoenix,
@traumaphoenix@chaos.social avatar

@scy this is still the most innocent “couldn’t have known” form, i’ve also seen people proxy internals through .main

traumaphoenix, to random
@traumaphoenix@chaos.social avatar

“be glad we only want equality, not revenge.”

traumaphoenix, to random
@traumaphoenix@chaos.social avatar

i’d just like to say i ran NixOS before it was cool 🦋

scy, to random German
@scy@chaos.social avatar

> Content created by others must be attributed, and use of AI must be disclosed.

Es kommt ja schon selten vor, dass ich auf mastodon.social neidisch bin.

https://mastodon.social/@Gargron/112118260677357857

traumaphoenix,
@traumaphoenix@chaos.social avatar

@scy probably “best effort”. that said, I think it’s pretty common to not think of memes as art and more of a… funny idea, I guess? ⚙️

scy, to random
@scy@chaos.social avatar

Ugh, so in one of the replies to my experiments with and associated tooling, @guerda asked "well, why not ?" and turns out, my main reasons against using restic (no compression and no exclude exceptions) are no longer valid, so I'm currently re-evaluating it.

Almost finished my writeup. And you know what? Both are really good.

My decision might boil down to performance against remote hosts and SSH vs SFTP, and whether "rclone serve restic" can save the day there.

traumaphoenix,
@traumaphoenix@chaos.social avatar

@scy restic uses zstd if I recall. zstd has heuristics that turn it into basically a no-op when it detects incompressible data. ⚙️

traumaphoenix,
@traumaphoenix@chaos.social avatar

@scy don’t know, but there’s a fairly simple check you can do to test for this behavior (note the transfer speed). in restic you’ll want to use dry runs or fresh repos, since it dedupes.

traumaphoenix,
@traumaphoenix@chaos.social avatar
scy, (edited ) to linux
@scy@chaos.social avatar

users! I'm curious how many of us are using "modern", "enhanced", "reimagined" versions of classic command-line tools. Think bat instead of cat, rg instead of grep, exa instead of ls.

If you don't use them, why? Is the installation overhead too much, e.g. because you're using a lot of machines? Does your brain need to stay compatible with the standard tools for some reason?

Feel free to write a reply, the poll can't possibly cover everything :)

traumaphoenix,
@traumaphoenix@chaos.social avatar

@scy nix has given me the ability to write and use nushell scripts on all of my machines

would i use them in production? ehh, definitely not nushell. age and yq, probably, fd too probably, but i think that’s my line 🦋

traumaphoenix, to random
@traumaphoenix@chaos.social avatar
traumaphoenix,
@traumaphoenix@chaos.social avatar

Punished Venom Crow

traumaphoenix, to random
@traumaphoenix@chaos.social avatar

wondering how healthy it is for our bulk storage cluster to be running databases. maybe we should add an SSD or two. ⚙️

traumaphoenix,
@traumaphoenix@chaos.social avatar

every 5 seconds you can hear the enterprise drives go "crrcrrcrr" as the database syncs. I mean yes they're enterprise drives but still, you have to wonder how much longer they'd last mostly idling instead.

traumaphoenix,
@traumaphoenix@chaos.social avatar

@eater yep, not a huge concern because it’s just a UniFi controller and an MQTT broker. ⚙️

ktemkin, (edited ) to random
@ktemkin@chaos.social avatar

another poll: do you speak a conlang?

traumaphoenix,
@traumaphoenix@chaos.social avatar

@ktemkin i wish my brain would let me, toki pona seems really neat 🦋

whitequark, (edited ) to random
@whitequark@mastodon.social avatar

got a Normal USB cable

it claims to do 100 W. don't think i would trust the flimsy piece of FR4 that forms both mechanical and electrical bits of the rotating joint on the left with 5 amps but thats just me

(there are two rotating joints in this cable. one rotates 360 deg and is disassembled. the other rotates about 180 deg and is integrated into the molded plug)

traumaphoenix,
@traumaphoenix@chaos.social avatar

@whitequark well at least if it breaks its probably not going to kill your iron, the way 20V5A killed my girlfriend’s Legion 🦋

traumaphoenix,
@traumaphoenix@chaos.social avatar

@whitequark speculating but it seems some pins got crossed on magnetic disconnect and it sent power down a data line

whitequark, to random
@whitequark@mastodon.social avatar

i've read a lot of blog posts about it, participated in a lot of arguments, but do you want to know the two things that actually made me a better (open source software/hardware) developer?

  1. experience
  2. not being in precarious situations where my living situation and to a lesser extent income feels like, or can, evaporate at any time, and not constantly being in the black-and-white states of mind that inevitably result from it
traumaphoenix,
@traumaphoenix@chaos.social avatar

@whitequark i would like to somehow teach my brain that my living situation isn’t that precarious because yeah,, 🦋

traumaphoenix,
@traumaphoenix@chaos.social avatar

@whitequark it’s always going to be somewhat precarious under capitalism but i’ll have some kind of advance warning

traumaphoenix,
@traumaphoenix@chaos.social avatar

@whitequark yeah i think my first employer really fucked with my perceptions there

basically they screwed us over in an incredibly short timeframe for something they fucked up doing

traumaphoenix, to random
@traumaphoenix@chaos.social avatar

Nyx go to sleep challenge (impossible). ⚙️

  • All
  • Subscribed
  • Moderated
  • Favorites
  • megavids
  • rosin
  • khanakhh
  • osvaldo12
  • Durango
  • mdbf
  • DreamBathrooms
  • ngwrru68w68
  • magazineikmin
  • thenastyranch
  • cisconetworking
  • Youngstown
  • slotface
  • kavyap
  • JUstTest
  • cubers
  • anitta
  • GTA5RPClips
  • tester
  • ethstaker
  • modclub
  • InstantRegret
  • everett
  • provamag3
  • Leos
  • normalnudes
  • tacticalgear
  • lostlight
  • All magazines