[-] danielquinn@lemmy.ca 11 points 2 days ago

What exactly are the risks here? Should Measles and even Polio make a comeback because of these idiots, is it just the lives of the idiots at risk, or is a resistance mutation that'd threaten everyone a risk?

[-] danielquinn@lemmy.ca 36 points 2 days ago* (last edited 2 days ago)

During the last decade, however, centrists and progressives alike continually fail to grasp that many voters have reached the point of ‘anything must be better than this.’

Holy fuck this is it.

This is how you elect fascists:

  1. Claim that as the progressive option, only you can fix these problems.
  2. Offer only token non-fixes, all while claiming the right would make it worse.

Once you've demonstrated that you can't be trusted, the public start to think: "Maybe the right isn't all that bad. It can't get much worse than this."

The only way to avoid fascism is to actually help the public. Gaslighting them into thinking that you're solving problems you refuse to solve only works for so long.

[-] danielquinn@lemmy.ca 2 points 3 days ago

Agreed on all fronts. In my activism experience in Ontario specifically, I remember how the province would often push back against municipalities that wanted to build something. NIMBYism is another big problem, but the often-overlooked issue is the fact that the private sector is deliberately holding back development because it's more profitable to do so, especially when interest rates are so high.

The amount of profit in building low-rise and even high-rise (non-luxury) developments just doesn't justify the costs, and when every unit you build effectively drives down the amount you can charge for for each unit, there's simply no incentive to build at the rate we need.

There are whole swathes of undeveloped or underdeveloped land in and around cities that would benefit from a crown corporation with deep pockets that would buy up land and build affordable housing on it. A body with the power to compel companies not using land to sell it to the state so that it can be developed for the public good, and with the political cover to piss off local NIMBY organisations without having to worry about political blowback.

[-] danielquinn@lemmy.ca 4 points 3 days ago

While I agree with you that the municipalities and provinces share a considerable amount of blame for the housing crisis, the suggestion that the federal government is somehow incapable of solving this problem is, I think, inaccurate.

I live in the UK now, where the same excuses could have been made in the 50s: the national government has no business sticking its nose into the affairs of cities and internal countries (the UK is weird). But they did it anyway. The national government spent mountains of money and resources, building an economy around building homes. The state built those homes, millions of them across the country.

Canada could do the same. Form a crown corporation that does nothing but builds high-density homes and sells or rents them at below-market rates to people in a given economic demographic. The "profit" in this model is a housing-secure nation full of happy, productive people. This, paired with an offer of big federal money exclusively for mass transit systems that connect these developments as well as a complete rollback of funding for road expansion, and Canada is well on its way to deflating the housing bubble and solving both the housing crisis and the environmental one.

But they don't want that, because the people that fund them like it when people are desperate.

[-] danielquinn@lemmy.ca 5 points 3 days ago

Not so long as they allow him to rule like a dictator.

Also, the suggestion that they got most big policies right is laughably false. Few governments on the planet have done more to prop up the fossil fuel industry than this one, even while our country literally burns from its effects. We continue to ship weapons supplies to genociders and have some sweet fuck all about the housing crisis.

Being "not as shit as the Conservatives" is an unreasonably low bar and we can do better.

[-] danielquinn@lemmy.ca 7 points 3 days ago* (last edited 3 days ago)

This is an excellent idea. Fortunately you're not the first to have it ;-)

You should look into alias.

[-] danielquinn@lemmy.ca 16 points 4 days ago

Dude lives in Germany for nearly 20 years, but is still stated as "from Saudi Arabia".

[-] danielquinn@lemmy.ca 2 points 4 days ago

I use mine with either my Jabra 75t Bluetooth earbuds, or my big Bose over-ear ones using an aftermarket Bluetooth adapter. Both are great.

419

cross-posted from: https://lemmy.ca/post/33126960

167
submitted 1 month ago by danielquinn@lemmy.ca to c/linux@lemmy.ml

From time to time, often after I've restored from sleep or finished playing a Steam game, one of my CPU cores is pinned at 100% with no indication of what might be doing it. Running htop, btop, or GNOME system monitor all show the same thing: CPU0 at 100% while the rest are doing near-nothing, and no process in particular seems to be using those resources.

If I restart, it's back to normal, and sometimes I can play a game in Steam or let the computer go to sleep and it doesn't do this, but it happens often enough that's annoying/confusing so I'd like to know if there's a way to either (a) diagnose which processes are using which CPU cores, or (b) somehow "reset" the checking of these values to make sure that something's not just being misreported.

This is a desktop system running Arch & GNOME.

62
Developing with Docker (danielquinn.org)
submitted 3 months ago* (last edited 2 months ago) by danielquinn@lemmy.ca to c/python@programming.dev

I've been writing code professionally for 24 years, 15 of which has been Python and 9 years of that with Docker. I got tired of running into the same complications every time I started a new job, so I wrote this. Maybe you'll find it useful, or it could even start a conversation, but this post has been a long time coming.

Update: I had a few requests for a demo repo as a companion to this post, so I wrote one today. It includes a very small Django demo user Docker, Compose, and GitLab CI.

[-] danielquinn@lemmy.ca 119 points 3 months ago

Oof, that video... I don't have enough patience to put up with that sort of thing either. I wonder how plausible a complete Rust fork of the kernel would be.

49
submitted 5 months ago* (last edited 5 months ago) by danielquinn@lemmy.ca to c/startrek@startrek.website

It would seem that I have far too much time on my hands. After the post about a Star Trek "test", I started wondering if there could be any data to back it up and... well here we go:

Those Old Scientists

Name Total Lines Percentage of Lines
KIRK 8257 32.89
SPOCK 3985 15.87
MCCOY 2334 9.3
SCOTT 912 3.63
SULU 634 2.53
UHURA 575 2.29
CHEKOV 417 1.66

The Next Generation

Name Total Lines Percentage of Lines
PICARD 11175 20.16
RIKER 6453 11.64
DATA 5599 10.1
LAFORGE 3843 6.93
WORF 3402 6.14
TROI 2992 5.4
CRUSHER 2833 5.11
WESLEY 1285 2.32

Deep Space Nine

Name Total Lines Percentage of Lines
SISKO 8073 13.0
KIRA 5112 8.23
BASHIR 4836 7.79
O'BRIEN 4540 7.31
ODO 4509 7.26
QUARK 4331 6.98
DAX 3559 5.73
WORF 1976 3.18
JAKE 1434 2.31
GARAK 1420 2.29
NOG 1247 2.01
ROM 1172 1.89
DUKAT 1091 1.76
EZRI 953 1.53

Voyager

Name Total Lines Percentage of Lines
JANEWAY 10238 17.7
CHAKOTAY 5066 8.76
EMH 4823 8.34
PARIS 4416 7.63
TUVOK 3993 6.9
KIM 3801 6.57
TORRES 3733 6.45
SEVEN 3527 6.1
NEELIX 2887 4.99
KES 1189 2.06

Enterprise

Name Total Lines Percentage of Lines
ARCHER 6959 24.52
T'POL 3715 13.09
TUCKER 3610 12.72
REED 2083 7.34
PHLOX 1621 5.71
HOSHI 1313 4.63
TRAVIS 1087 3.83
SHRAN 358 1.26

Discovery

Important Note: As the source material is incomplete for Discovery, the following table only includes line counts from seasons 1 and 4 along with a single episode of season 2.

Name Total Lines Percentage of Lines
BURNHAM 2162 22.92
SARU 773 8.2
BOOK 586 6.21
STAMETS 513 5.44
TILLY 488 5.17
LORCA 471 4.99
TARKA 313 3.32
TYLER 300 3.18
GEORGIOU 279 2.96
CULBER 267 2.83
RILLAK 205 2.17
DETMER 186 1.97
OWOSEKUN 169 1.79
ADIRA 154 1.63
COMPUTER 152 1.61
ZORA 151 1.6
VANCE 101 1.07
CORNWELL 101 1.07
SAREK 100 1.06
T'RINA 96 1.02

If anyone is interested, here's the (rather hurried, don't judge me) Python used:

#!/usr/bin/env python

#
# This script assumes that you've already downloaded all the episode lines from
# the fantastic chakoteya.net:
#
# wget --accept=html,htm --relative --wait=2 --include-directories=/STDisco17/ http://www.chakoteya.net/STDisco17/episodes.html -m
# wget --accept=html,htm --relative --wait=2 --include-directories=/Enterprise/ http://www.chakoteya.net/Enterprise/episodes.htm -m
# wget --accept=html,htm --relative --wait=2 --include-directories=/Voyager/ http://www.chakoteya.net/Voyager/episode_listing.htm -m
# wget --accept=html,htm --relative --wait=2 --include-directories=/DS9/ http://www.chakoteya.net/DS9/episodes.htm -m
# wget --accept=html,htm --relative --wait=2 --include-directories=/NextGen/ http://www.chakoteya.net/NextGen/episodes.htm -m
# wget --accept=html,htm --relative --wait=2 --include-directories=/StarTrek/ http://www.chakoteya.net/StarTrek/episodes.htm -m
#
# Then you'll probably have to convert the following files to UTF-8 as they
# differ from the rest:
#
# * Voyager/709.htm
# * Voyager/515.htm
# * Voyager/416.htm
# * Enterprise/41.htm
#

import re
from collections import defaultdict
from pathlib import Path

EPISODE_REGEX = re.compile(r"^\d+\.html?$")
LINE_REGEX = re.compile(r"^(?P<name>[A-Z']+): ")

EPISODES = Path("www.chakoteya.net")
DISCO = EPISODES / "STDisco17"
ENT = EPISODES / "Enterprise"
TNG = EPISODES / "NextGen"
TOS = EPISODES / "StarTrek"
DS9 = EPISODES / "DS9"
VOY = EPISODES / "Voyager"

NAMES = {
    TOS.name: "Those Old Scientists",
    TNG.name: "The Next Generation",
    DS9.name: "Deep Space Nine",
    VOY.name: "Voyager",
    ENT.name: "Enterprise",
    DISCO.name: "Discovery",
}


class CharacterLines:
    def __init__(self, path: Path) -> None:
        self.path = path
        self.line_count = defaultdict(int)

    def collect(self) -> None:
        for episode in self.path.glob("*.htm*"):
            if EPISODE_REGEX.match(episode.name):
                for line in episode.read_text().split("\n"):
                    if m := LINE_REGEX.match(line):
                        self.line_count[m.group("name")] += 1

    @property
    def as_tablular_data(self) -> tuple[tuple[str, int, float], ...]:
        total = sum(self.line_count.values())
        r = []
        for k, v in self.line_count.items():
            percentage = round(v * 100 / total, 2)
            if percentage > 1:
                r.append((str(k), v, percentage))
        return tuple(reversed(sorted(r, key=lambda _: _[2])))

    def render(self) -> None:
        print(f"\n\n# {NAMES[self.path.name]}\n")
        print("| Name             | Total Lines | Percentage of Lines |")
        print("| ---------------- | :---------: | ------------------: |")
        for character, total, pct in self.as_tablular_data:
            print(f"| {character:16} | {total:11} | {pct:19} |")


if __name__ == "__main__":
    for series in (TOS, TNG, DS9, VOY, ENT, DISCO):
        counter = CharacterLines(series)
        counter.collect()
        counter.render()
[-] danielquinn@lemmy.ca 88 points 7 months ago* (last edited 7 months ago)

Honestly, after having served on a Very Large Project with Mypy everywhere, I can categorically say that I hate it. Types are great, type checking is great, but applying it to a language designed without types in mind is a recipe for pain.

264
submitted 8 months ago by danielquinn@lemmy.ca to c/linux@lemmy.ml

I'm working on a some materials for a class wherein I'll be teaching some young, wide-eyed Windows nerds about Linux and we're including a section we're calling "foot guns". Basically it's ways you might shoot yourself in the foot while meddling with your newfound Linux powers.

I've got the usual forgetting the . in lines like this:

$ rm -rf ./bin

As well as a bunch of other fun stories like that one time I mounted my Linux home folder into my Windows machine, forgot I did that, then deleted a parent folder.

You know, the war stories.

Tell me yours. I wanna share your mistakes so that they can learn from them.

Fun (?) side note: somehow, my entire ${HOME}/projects folder has been deleted like... just now, and I have no idea how it happened. I may have a terrible new story to add if I figure it out.

[-] danielquinn@lemmy.ca 105 points 10 months ago

Actually, I stepped away from the project 'cause I stopped using it altogether. I started the project to satisfy the British government with their ridiculous requirements for proof of my relationship with my wife so I could live here. Once I was settled though and didn't need to be able to bring up flight itineraries from 5 years ago, it stopped being something I needed.

Well that, and lemme tell you, maintaining a popular Free software project is HARD. Everyone has an idea of where stuff should go, but most of the contributions come in piecemeal, so you're left mostly acting as the one trying to wrangle different styles and architectures into something cohesive... while you're also holding down a day job. It was stressful to say the least, and with a kid on the way, something had to give.

But every once in a while I consider installing paperless-ngx just to see how it's come along, and how much has changed. I'm absolutely delighted that it's been running and growing in my absence, and from the screenshots alone, I see that a lot of the ideas people had when I was helming made it in in the end.

[-] danielquinn@lemmy.ca 130 points 10 months ago

Ha! I wrote it! Well the original anyway. It's been forked a few times since I stepped away.

So yeah, I think it's pretty cool 😆

20

I've been playing a lot of Fallout 4 over the holidays. I started and finished the Nuka World DLC (killed all the baddies), made it to level 90, etc.

Today I was playing on my Deck as the battery got a little low (11%) so I saved my game, exited the game, and went to shut down.

As it was shutting down, the Deck displayed a message, something like "Syncing to Steam Cloud" as the logo was spinning.

A few hours later, on a full charge, I booted it back up, started Fallout 4 again and... some of my old saves are there, but only about 30% of them, and critically not the most recent ones.

Has this ever happened to anyone else? Is this a known issue? Can I fix it, or report it? I've basically lost interest in finishing the game now.

735

His original post , titled I can't sleep, is some brilliant writing. When we talk about the chilling effect that criticism of Israel creates in industries everywhere (including ours) this is what that looks like.

126

I needed something for a presentation I'm doing on advanced Linux, so I thought something like this might be appropriate.

Annoyingly, I can't seem to get Bing to generate an image that isn't square.

34
Ash Vs Bash (lemmy.ca)
submitted 1 year ago by danielquinn@lemmy.ca to c/linux@lemmy.ml

[For reference, I'm talking about Ash in Alpine Linux here, which is part of BusyBox.]

I thought I knew the big differences, but it turns out I've had false assumptions for years. Ash does support [[ double square brackets ]] and (as best I can tell) all of Bash's logical trickery inside them. It also supports ${VARIABLE_SUBSTRINGS:5:12}` which was another surprise.

At this stage, the only things I've found that Bash can do that Ash can't are:

  • Arrays, which Bash doesn't seem to do well anyway
  • Brace expansion, which is awesome but I can live without it.

What else is there? Did Ash used to be more limited? The double square bracket thing really surprised me.

view more: next ›

danielquinn

joined 2 years ago