Skip to content

Piero Bosio Social Web Site Personale Logo Fediverso

Social Forum federato con il resto del mondo. Non contano le istanze, contano le persone

Update: a few hours before the deadline, we reached the goal!!!

Uncategorized
17 1 15

Gli ultimi otto messaggi ricevuti dalla Federazione
  • this fucking college radio dj. "that was the Russian band Aquarium, playing, uh, something I have no idea how to pronounce... but the bass line speaks for itself!"

    read more

  • @swelljoe That file access problem sounds like the classic sandboxed package issue. Can't recall if it's Snap or AppImage that does it, though.*

    Whichever one it is, there's an arcane command - or a GUI/TUI - that can change the access settings for individual packages.

    *Sorry, it's been so long since I've used either package type that my memory is rusty. Both make me nope out. šŸ˜…

    read more

  • Sgombero askatasuna. la lotta continua: in serata passeggiata con il comitato di quartiere, all’ultimo dell’anno street parade
    @anarchia
    Torino. Continua la lotta contro lo sgombero dello storico centro sociale Askatasuna, avvenuto lo scorso 18 dicembre. All’esterno dello stabile di corso Regina Margherita 47, blindato

    read more

  • Also, I keep killing my editors (Zed and VS Code) trying to open a 32MB file with exactly one really long line of JSON. This doesn't seem like it ought to be "big" to any modern editor on a modern computer with 64GB of RAM, but here we are. jq can pretty print it without any trouble, so I could make a copy that's pre-parsed into individual lines, but it doesn't seem like I ought to have to massage text to even be able to load it.

    Back to old reliable Neovim, with `:%!jq .` to format it.

    read more

  • Current* conditions near Fairport Harbor, OH:

    read more

  • Computers are so fucking weird. Every day there's some new thing. Chromium on Linux (Fedora 43) is in some kind of sandbox, so I can't open local files, but only some of them? All of the directories that were created by the desktop (Documents, Downloads, Music, Videos, Pictures, etc.) are accessible, as well as a few hidden directories (.local, .nv, .pki, .var), but nothing else is. I can't even type it in explicitly and fully, it's a 404.

    Firefox _can_ reach all files my user has access to.

    read more

  • @alice wait... You take the locks off fences and bridges?

    read more

  • Well, my fingers almost froze, but I came back from my walk with five new love locks 🩵

    I'm a quarter of the way to my goal of 1000. At this pace, it'll be maybe three more years before my art installation is ready.

    read more
Post suggeriti
  • 0 Votes
    2 Posts
    4 Views
    @PythonPeak video removed by the uploader.
  • 0 Votes
    1 Posts
    16 Views
    cross-posted from: https://lemmy.dbzer0.com/post/55501944 Hey, I’ve been kicking around an idea for a bot: it would look for fanfiction links shared in a server and keep track of which ones get shared the most. The concept: Track sites like AO3, FanFiction.net, ScribbleHub, etc. Count how often each link gets posted Commands to see the ā€œtopā€ links or which domains are tracked It’s just a rough idea, I haven’t built it yet. Curious if anyone thinks this would actually be useful or has tips for implementing it without overcomplicating things. import re import json import discord from collections import Counter from discord.ext import commands TOKEN = "YOUR_BOT_TOKEN" intents = discord.Intents.default() intents.message_content = True bot = commands.Bot(command_prefix="!", intents=intents) # Domain list you want to track (lower-case) TRACK_DOMAINS = { "archiveofourown.org", "fanfiction.net", "forum.questionablequesting.com", "forums.spacebattles.com", "forums.sufficientvelocity.com", "webnovel.com", "hentai-foundry.com", "scribblehub.com", } link_pattern = re.compile(r'https?://\S+') link_counter = Counter() def domain_of_url(url: str) -> str | None: try: # Extract domain part from urllib.parse import urlparse parsed = urlparse(url) domain = parsed.netloc.lower() # remove leading ā€œwww.ā€ if domain.startswith("www."): domain = domain[4:] return domain except Exception: return None def save_links(): with open("links.json", "w") as f: # convert counts to dict json.dump(dict(link_counter), f) def load_links(): try: with open("links.json") as f: data = json.load(f) for link, cnt in data.items(): link_counter[link] = cnt except FileNotFoundError: pass @bot.event async def on_ready(): load_links() print(f"Bot is ready. Logged in as {bot.user}") @bot.event async def on_message(message): if message.author.bot: return links = link_pattern.findall(message.content) for link in links: dom = domain_of_url(link) if dom in TRACK_DOMAINS: link_counter[link] += 1 await bot.process_commands(message) @bot.command(name="links") async def links(ctx, top: int = 10): if not link_counter: await ctx.send("No links recorded.") return sorted_links = sorted(link_counter.items(), key=lambda x: x[1], reverse=True) display = sorted_links[:top] lines = [f"{link} — {count}" for link, count in display] await ctx.send("**Top links:**\n" + "\n".join(lines)) @bot.command(name="domains") async def domains(ctx): """Show which domains are tracked.""" await ctx.send("Tracked domains: " + ", ".join(sorted(TRACK_DOMAINS))) @bot.command(name="dump") async def dump(ctx): """For admin: dump full counts (might be large).""" if not link_counter: await ctx.send("No data.") return lines = [f"{link} — {cnt}" for link, cnt in sorted(link_counter.items(), key=lambda x: x[1], reverse=True)] chunk = "\n".join(lines) # Discord message length limit; you may need to split await ctx.send(f"All counts:\n{chunk}") @bot.event async def on_disconnect(): save_links() bot.run(TOKEN)
  • 0 Votes
    1 Posts
    9 Views
    Something in #VSCode just wrote a #JupyterNotebook in my name, seemingly based on the name I gave to the #Python project. When I saw that the file existed, I assumed it was just some ā€œHello, worldā€ like thing.Eventually I looked at it.It was extensive had lots of sentences like, ā€œI haven't yet decided how to represent digits larger than 9ā€, which either are not true or non-sensical for my project.I am pleased that I could this before that ever made it to a public repository. And I am extremely annoyed that I could have published some AI generated text in my name.I’m not in principle opposed to using AI to assist in development. After all, linters are AI as far as I am concerned. But something that writes crap in my name without explicitly drawing my attention to the fact that it is doing so is not the kind of thing that will win me over to AI.
  • WTF?

    Uncategorized slop gentoo python github
    2
    0 Votes
    2 Posts
    20 Views
    @mgorny Wow, that a dick.