Searching yarn

Twts matching #BUG
Sort by: Newest, Oldest, Most Relevant
In-reply-to » This document is the result of a series of discussions between Robert "Uncle Bob" Martin and John Ousterhout, held between September 2024 and February 2025. The text addresses three main topics: method length, comments, and Test Driven Development (TDD). https://github.com/johnousterhout/aposd-vs-clean-code/blob/main/README.md This is something to read and reflect on for days.

Amd of course, TDD! I tried that, but it doesn’t work all that great for me in its strict form. I have the feeling that coming up with a single new failing test, making it pass, maybe some refactoring, rinse and repeat wastes significantly more time than doing it in – what they call – the “bundle” approach. Coming up with several tests in advance and then writing the code or vise versa is usually much quicker. I do find that more enjoyable, it also helps me to reduce smaller context switches. I can focus on either the tests or the production code.

As for the potentially reduced code coverage with a non-TDD approach, I can easily see which parts are lacking tests and hand them in later. So, that’s largely a specious argument. Granted, I can forget to check the coverage or simply ignore it.

I agree with John, TDD results in less elegant code or requires more refactoring to tidy it up. Sometimes, it’s also not entirely clear at the beginning how the API should really look like. It doesn’t happen often, but it does happen. Especially when experimenting or trying out different approaches. With TDD, I then also have to refactor the tests which is not only annoying, but also involves the danger of accidentally breaking them.

TDD only works really well, if you have super tiny functions. But we already established that I typically don’t like tiny methods just for the purpose of them being extremely short.

When fixing a bug, I usually come up with a failing test case first to verify that my repaired code later actually resolves the problem. For new code, it depends, sometimes tests first, sometimes the productive code first. Starting off with the tests requires the API to be well defined beforehand.

​ Read More

The DOS 3.3 SYS.COM bug hunt!
Last year somebody reported a problem with the DOS 3.3 SYS.COM command when used with NetDrive. They started with a valid FAT12 image, ran SYS.COM to make it bootable, and then they were not able to mount the image using NetDrive again. Running SYS.COM against the image had broken something. Besides copying the operating system’s hidden files to the target drive letter, SYS.COM also copies some boot code into the first sector of the disk. In general it does not make sense 
 ⌘ Read more

​ Read More
In-reply-to » (#jzdbrkq) What do you think? Where is the problem?

@andros@twtxt.andros.dev I believe you have just reproduced the bug
 it looks like you’ve replayed to a twt but the hash is wrong. I can see the hash here from Jenny, but it doesn’t look like it corresponds to any{twt,thing}. if you check it out on any yarn instance it won’t look like a replay.

​ Read More
In-reply-to » @andros is it me or twtxt-el generates a wrong twt hash when I use the [ ↳ Reply to twt ] button?

I don’t think so, at least the tests I did passed. If you’re pretty sure it’s a bug, please create an issue in the repository with the specific case and I’ll investigate it.
There are 2 buttons to make replicas, one makes a replica in the thread where the twt is located (this is the one that should be used the most, as it serves a thread), the other creates a replica to a specific twt.
I’ll let you know a bit about the status: I’m just now implementing the thread screen. There you can be sure where you are. It’s a bit confusing right now, sorry. I think the client is still in alpha. When I’ve finished what I’m doing, and the direct message system, I’ll freeze development and focus on creating more tests, looking for bugs and making small visual adjustments.

​ Read More

Fedora should not push its users to its own Flatpak repository
Unlike most (all?) other distributions with built-in Flatpak support, Fedora maintains its own repository of Flatpak applications. Everyone else defaults to using Flathub, where developers of applications themselves tend to publish their Flatpaks. Fedora’s ‘shadow Flathub’ sometimes leads to problems, with Fedora-made Flatpaks containing bugs and brokenness, while presenting themselves as official, develope 
 ⌘ Read more

​ Read More
In-reply-to » Have you ever had to refactor a project that was not documented? Any suggestions?

@andros@twtxt.andros.dev I suggest to not touch it and work on a different project instead. :-D

No, in all seriousness, that’s a tough one. Try to figure out the requirements and write tests to cover them. In my experience, if there is no good documention, tests might also be lacking. It goes without saying that you have to understand the code segments first before you can begin to refactor them. Commit even earlier and more often than usual, this will help you bisecting potentially introduced bugs later on. Basically baby steps.

But it also depends on the amount of refactoring required. Maybe just scrap it entirely and start from scratch. This might not be feasible due to e.g. the overall project size, though.

​ Read More
In-reply-to » @eapl.me Read flags are so simple, yet powerful in my opinion. I really don't understand why this is not a thing in most twtxt clients. It's completely natural in e-mail programs and feed readers, but it hasn't made the jump over to this domain.

@eapl.me@eapl.me Yeah, you need some kind of storage for that. But chances are that there’s already a cache in place. Ideally, the client remembers etags or last modified timestamps in order to reduce unnecessary network traffic when fetching feeds over HTTP(S).

A newsreader without read flags would be totally useless to me. But I also do not subscribe to fire hose feeds, so maybe that’s a different story with these. I don’t know.

To me, filtering read messages out and only showing new messages is the obvious solution. No need for notifications in my opinion.

There are different approaches with read flags. Personally, I like to explicitly mark messages read or unread. This way, I can think about something and easily come back later to reply. Of course, marking messages read could also happen automatically. All decent mail clients I’ve used in my life offered even more advanced features, like delayed automatic marking.

All I can say is that I’m super happy with that for years. It works absolutely great for me. The only downside is that I see heaps of new, despite years old messages when a bug causes a feed to be incorrectly updated (https://twtxt.net/twt/tnsuifa). ;-)

​ Read More
In-reply-to » @lyse As far as I know, they're still visible in the Web UI. Although, in the mobile app and youtube.com, I believe it tells you that the video isn't available without having to click on it. They don't tell you that in the RSS feed, and I agree; it gets annoying.

@mckinley@twtxt.net And there is the bracketed text duplication bug again
 Actually with lots of twts. Did you edit a twt? Do you remember? /cc @prologic@twtxt.net

​ Read More

Three years of ephemeral NixOS: my experience resetting root on every boot
We had a bit of a bug caused by changes we made to make quotes look better, but we’ve fixed it now, so we’re back on track (you may need to do a force-reload in your browser). Sorry for the disruption – and if you want to stay up-to-date on such issues next time it (inevitably) happens, you should follow the OSNews Fedi account (or just bookmark it without following it, if you’re not 
 ⌘ Read more

​ Read More
In-reply-to » @bender @prologic I can reproduce this locally, too. But it doesn't matter if I follow the feed or not. With JS enabled, hitting "Reply" opens a textarea with @<url>. Submitting this writes @<domain url> instead of @<nick url> in the feed.

While I now have a somewhat working fix for it in yarnd (https://git.mills.io/yarnsocial/yarn/pulls/1232), I also have the feeling that I should fix literal formatting in lextwt as well. This also uncovered more bugs I believe: https://git.mills.io/yarnsocial/go-lextwt/pulls/28

But then there is also the question why the textarea is populated with @<url> in the first place rather than @<nick url> or yarnd’s own @nick@domain/@nick syntax. It indeed has to do something with whether I follow the mentioned feed or not.

Anyway, something to investigate for future Lyse or maybe @prologic@twtxt.net and/or @xuu@txt.sour.is. G’night!

​ Read More

The invalid 68030 instruction that accidentally allowed the Mac Classic II to successfully boot up
A bug in the ROM for the Macintosh II was recently discovered that causes a crash when booting in 32-bit mode. Doug Brown discovered and documented the bug while playing with the MAME debugger. Why did it never show up before? It seems a quirk in Motorola’s 68030 CPU inadvertently fixes it when executing an illegal instruction that shou 
 ⌘ Read more

​ Read More

MorphOS 3.19 released
It’s been about 18 months, but we’ve got a new release for MorphOS, the Amiga-like operating system for PowerPC Macs and some other PowerPC-based machines. Going through the list of changes, it seems MorphOS 3.19 focuses heavily on fixing bugs and addressing issues, rather than major new features or earth-shattering changes. Of note are several small but important updates, like updated versions of OpenSSL and OpenSSH, as well as a ton of new filetype definitions – and so much more. Havin 
 ⌘ Read more

​ Read More
In-reply-to » đŸ€” Prosoal: Disallowed the @<url> form of mentions. Strictly require that all mentions include a nickname/name; i.e: @<name url>.

@prologic@twtxt.net If you’ve got the feed URL in yarnd’s cache, you can easily look up a missing nick. If you can’t find it, just show the URL (or maybe just the domain name to be halfway consistent with this @nick@domain thing that yarnd invented) and be done. It’s really that simple.

When yarnds peer with each other, the odds of actually having come across that feed URL in the past are higher than with traditional clients that only have their local set of subscribed feeds. One additional improvment would be to also look at all the mentions and see if somebody used a nick for that URL and go with that.

Yeah, yarnd currently renders some really weird shit when the mention contains just a URL, but I’d call that a bug for sure.

Personally, I do not like the @nick@domain syntax at all. It looks silly to my eyes. What might have also contributed is the fact of this mentions syntax gotten screwed up so many times by yarnd in the past. But that’s a totally different topic.

​ Read More
In-reply-to » Hello @movq . Did you fixed jenny bug which causes fetching long ids from yarn instances on feeds like https://ciberlandia.pt/@marado.txt ? I'm asking because i want to store links in brackets on some of my posts and don't want to confuse jenny users

@doesnmppsflt@doesnm.p.psf.lt Not sure which bug you’re referring to. đŸ€” (Did I forget?)

Those long IDs like (#113797927355322708) are simply part of that feed. Looks like the author just dumps ActivityPub IDs into twtxt. I think this used to work in the past, but the corresponding spec (https://twtxt.dev/exts/hash-tag.html) has been deprecated and jenny doesn’t support – actually, jenny never supported that.

jenny can only group threads by exactly one criterium (because it writes a Message-ID into the mail file) and that’s the regular twt hash. So, anything else, like people doing “#CoolTopic”, isn’t possible.

​ Read More
In-reply-to » tried building the yarn social app for android but wahhh android studio and flutter scare me... big ass IDEs and SDKs and shit not worth it

Don’t waste your time. You can find builds in dist directory. Also it’s abandoned app which have more bugs

​ Read More

Okay, this is pretty cool. My 8086 toy OS running on my old Pentium from an actual floppy disk. 😍 I just love that sound and the feeling of using floppies. This brings back so many memories from my early DOS days.

The cp-unopt program copies a file and intentionally uses small unaligned reads/writes (hopefully triggers more bugs).

The I/O cache works “okay-ish”, I guess. When sha1 runs, it has to do a few reads for the first file and basically none for the second one. Both could have been served entirely from the cache, theoretically. (But even just having an I/O cache in the first place speeds up things dramatically.)

Notice how there’s an EA file. That’s a left-over from OS/2, because I copied some files to the floppy using OS/2. In other words, my FAT12 implementation survives OS/2 writing to it. đŸ„ł (But I guess it should show up as EA DATA.SF. My current code starts at the left and stops at the first space.)

https://movq.de/v/d4d50d3c74/los86-on-p133-from-floppy-small2.mp4

​ Read More
In-reply-to » Imagine if all computer UIs would act like the UI from my NAS system... I feel I need to be waiting for output from the machine like it's 1973.

Yeah, @movq@www.uninformativ.de! “Sorry boss, I accidentally removed the bug report, because the button suddenly materialized under my cursor.” :-D

Luckily, I do not have to deal with that UI from hell for three and a half weeks very soon.

​ Read More

Wow! Just Wow! 😼

Image

Discovered this whilst trying to debug why my Youtube frontend no longer works:

$ youtube-dl 'https://www.youtube.com/watch?v=YpiK1FMy2Mg'
[youtube] YpiK1FMy2Mg: Downloading webpage
WARNING: unable to extract uploader id; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see  https://yt-dl.org/update  on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
ERROR: unable to download video data: HTTP Error 403: Forbidden

​ Read More

Reading about browser security measures and getting sad we don’t live in a world where cross-site scripting is a feature instead of a bug.

​ Read More
In-reply-to » @movq going a little sideways on this, "*If twtxt/Yarn was to grow bigger, then this would become a concern again. But even Mastodon allows editing, so how much of a problem can it really be? 😅*", wouldn't it preparing for a potential (even if very, very, veeeeery remote) growth be a good thing? Mastodon signs all messages, keeps a history of edits, and it doesn't break threads. It isn't a problem there.😉 It is here.

@prologic@twtxt.net, there is a parser bug on parent. Specifically on this portion:

"*If twtxt/Yarn was to grow bigger, then this would become a concern again. *But even Mastodon allows editing*, so how
+much of a problem can it really be? 😅*"

​ Read More
In-reply-to » An alternate idea for supporting (properly) Twt Edits is to denoate as such and extend the meaning of a Twt Subject (which would need to be called something better?); For example, let's say I produced the following Twt:

@quark@ferengi.one I don’t really mind if the twt gets edited before I even fetch it. I think it’s the idea of my computer discarding old versions it’s fetched, especially if it’s shown them to me, that bugs me.

But I do like @movq@www.uninformativ.de’s suggestion on this thread that feeds could contain both the original and the edited twt. I guess it would be up to the author.

​ Read More
In-reply-to » An alternate idea for supporting (properly) Twt Edits is to denoate as such and extend the meaning of a Twt Subject (which would need to be called something better?); For example, let's say I produced the following Twt:

@prologic@twtxt.net I wouldn’t want my client to honour delete requests. I like my computer’s memory to be better than mine, not worse, so it would bug me if I remember seeing something and my computer can’t find it.

​ Read More

On the Subject of Feed Identities; I propose the following:

  1. Generate a Private/Public ED25519 key pair
  2. Use this key pair to sign your Twtxt feed
  3. Use it as your feed’s identity in place of # url = as # key = ...

For example:

$ ssh-keygen -f prologic@twtxt.net
$ ssh-keygen -Y sign -n prologic@twtxt.net -f prologic@twtxt.net twtxt.txt

And your feed would looke like:

# nick        = prologic
# key         = SHA256:23OiSfuPC4zT0lVh1Y+XKh+KjP59brhZfxFHIYZkbZs
# sig         = twtxt.txt.sig
# prev        = j6bmlgq twtxt.txt/1
# avatar      = https://twtxt.net/user/prologic/avatar#gdoicerjkh3nynyxnxawwwkearr4qllkoevtwb3req4hojx5z43q
# description = "Problems are Solved by Method" 🇩đŸ‡șđŸ‘šâ€đŸ’»đŸ‘šâ€đŸŠŻđŸč♔ 🏓⚯ đŸ‘šâ€đŸ‘©â€đŸ‘§â€đŸ‘§đŸ›„ -- James Mills (operator of twtxt.net / creator of Yarn.social đŸ§¶)

2024-06-14T18:22:17Z	(#nef6byq) @<bender https://twtxt.net/user/bender/twtxt.txt>  Hehe thanks! 😅 Still gotta sort out some other bugs, but that's tomorrows job đŸ€ž
...

Twt Hash extension would change of course to use a feed’s ED25519 public key fingerprint.

​ Read More
In-reply-to » There is a bug in yarnd that's been around for awhile and is still present in the current version I'm running that lets a person hit a constructed URL like

@prologic@twtxt.net I believe you are not seeing the problem I am describing.

Hit this URL in your web browser:

https://twtxt.net/external?nick=lovetocode999&uri=https://socialmphl.com/story19510368/doujin

That’s your pod. I assume you don’t have a user named lovetocode999 on your pod. Yet that URL returns HTTP status 200, and generates HTML, complete with a link to https://socialmphl.com/story19510368/doujin, which is not a twtxt feed (that’s where the twtxt.txt link goes if you click it). That link could be to anything, including porn, criminal stuff, etc, and it will appear to be coming from your twtxt.net domain.

What I am saying is that this is a bug. If there is no user lovetocode999 on the pod, hitting this URL should not return HTTP 200 status, and it should definitely not be generating valid HTML with links in it.

Edit: Oops, I misunderstood the purpose of this /external endpoint. Still, since the uri is not a yarn pod, let alone one with a user named lovetocode999 on it, I stand by the belief that URLs like this should be be generating valid HTML with links to unknown sites. Shouldn’t it be possible to construct a valid target URL from the nick and uri instead of using the pod’s /external endpoint?

​ Read More

There is a bug in yarnd that’s been around for awhile and is still present in the current version I’m running that lets a person hit a constructed URL like

YOUR_POD/external?nick=lovetocode999&uri=https://socialmphl.com/story19510368/doujin

and see a legitimate-looking page on YOUR_POD, with an HTTP code 200 (success). From that fake page you can even follow an external feed. Try it yourself, replacing “YOUR_POD” with the URL of any yarnd pod you know. Try following the feed.

I think URLs like this should return errors. They should not render HTML, nor produce legitimate-looking pages. This mechanism is ripe for DDoS attacks. My pod gets roughly 70,000 hits per day to URLs like this. Many are porn or other types of content I do not want. At this point, if it’s not fixed soon I am going to have to shut down my pod. @prologic@twtxt.net please have a look.

​ Read More
In-reply-to » @stigatle / @abucci My current working theory is that there is an asshole out there that has a feed that both your pods are fetching with a multi-GB avatar URL advertised in their feed's preamble (metadata). I'd love for you both to review this PR, and once merged, re-roll your pods and dump your respective caches and share with me using https://gist.mills.io/

@prologic@twtxt.net Try hitting this URL:

https://twtxt.net/external?nick=nosuchuser&uri=https://foo.com

Change nosuchuser to any phrase at all.

If you hit https://twtxt.net/external?nick=nosuchuser , you’re given an error. If you hit that URL above with the uri parameter, you can a legitimate-looking page. I think that is a bug.

​ Read More
In-reply-to » Hack of the day: running watch -n 60 rm -rf /tmp/yarn-avatar-* in a tmux because all of a sudden, without warning, yarnd started throwing hundreds of gigabytes of files with names like yarn-avatar-62582554 into /tmp, which filled up the entire disk and started crashing other services.

@prologic@twtxt.net Sure, but why would this start happening all of a sudden today? Nothing like this has happened before. Is this a known bug?

​ Read More

Plus on a de compĂ©tences techniques, plus on peut utiliser des technologies “basses”, et plus on est incompĂ©tent, plus on utilise une technologie haut niveau qui dĂ©cide Ă  notre place. Donc il faut essayer d’enseigner la technologie la plus “basse” possible pour permettre aux enfants d’ĂȘtre en mesure de comprendre ce qu’ils font. - Marcello Vitali-Rosati, auteur de “Éloge du bug”.

​ Read More

👋 If y’all notice any weird quirks or UI/UX bugs of late on my pod, please let me know! 🙏 For those that have a Javascript enabled web browser will notice (hopefully) a SPA (single page app) like experience, even in Mobile! No more full page refreshes! All this without writing a single line of Javascript (let alone React or whatever) 😅 – HTMX is pretty damn cooL! 😎 #htmx

​ Read More

I am supposed to come to office today, but I have caught the same cold bug wife has had for the last three days, so I am staying remote to spare cube-mates. Nose stuck, dripping, and a general slight sense of malaise is what I am feeling right now.

​ Read More
In-reply-to » OK time to put this to the test, I ended up setting my $VISUAL env {-here-} variable, so that jenny can launch neovim instead of plain old vi like {-here-} it is instructed in the code. But as you can see, I still get these {-here-} wired new lines every ~70th character (marked them with {-here-})

I might have found the actual source of my problem.

Jenny uses an .eml file when composing a twt 

and vim kinda auto formats it and inserts in those line breaks every ~70 character.

Then, I stumbled upon this link where Where someone reports that saving a .eml into a .txt might
 corrupt the data?

​ Read More
In-reply-to » @xuu That was one of the horror puzzles where I had to look for help. đŸ„Ž I modelled my solution after this: https://www.youtube.com/watch?v=2pDSooPLLkI (I can’t explain it better than the video anyway.) It takes a second on my machine and that’s with my own hashmap implementation which is probably not the fastest one.

i am wondering if maybe i need a better heap like a btree backed one instead of just list sort on Dequeue.

I found a bug where i didnt include an open/closed list that seemed to shave off a little. right now it runs in about 70 seconds on my machine.. it takes over the 300s limit when it runs on the testrunner on the same box.. docker must be restricting resources for it.

I might come back to it after i work through improving my code for day 23. Its similar but looking for the longest path instead of shortest.

​ Read More
In-reply-to » Could pumping CO2 under Canada's coast cause earthquakes? Injecting CO2 underground might increase pressure along geological faults and cause earthquakes, but a report concludes the risk is minimal for a proposed CO2 storage site near Vancouver Island ⌘ Read more

@New_scientist@feeds.twtxt.net hello @prologic@twtxt.net here’s another feed that’s spewing multiple copies of the same post. This one above is repeated 8 times. @awesome-scala-weekly@feeds.twtxt.net now has 13 copies of each post every week. This definitely looks like a bug in whatever code is generating these feeds, because the source feeds don’t have multiple copies of the original posts:

I forget whether I filed an issue on this before, but can you tell me where I should do that?

​ Read More

I have used Linux for most my life, and it hat been my daily driver for nearly two decades now. I have been bugged recently how when I exit the terminal buffer has not been cleared leaving whatever contents available to the next user to view.

a quick man zsh I found the STARTUP/SHUTDOWN FILES, and then a quick search on resetting the termianl buffer led me to <esc>c or printf "\033c".

In five minutes something which has bothered me for who knows how long was resolved. Just needed some motivation to figure it out.

​ Read More