<?xml version="1.0" encoding="utf-8" standalone="no"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" version="2.0"><channel><title>The Daily WTF</title><link>http://thedailywtf.com/</link><description>Curious Perversions in Information Technology</description><lastBuildDate>Thu, 07 May 2026 07:45:56 GMT</lastBuildDate><item><dc:creator>Remy Porter</dc:creator><title>CodeSOD: Please Find, Rewind</title><link>https://thedailywtf.com/articles/please-find-rewind</link><category>CodeSOD</category><pubDate>Wed, 06 May 2026 06:30:00 GMT</pubDate><guid>https://thedailywtf.com/articles/please-find-rewind</guid><description>&lt;p&gt;As &lt;a href="https://thedailywtf.com/articles/non-cogito-ergo-c-str"&gt;previously discussed&lt;/a&gt;, C++ took a surprisingly long time to get a &amp;#34;starts with&amp;#34; function for strings. It took even longer to get a function called &amp;#34;contains&amp;#34;. In part, that&amp;#39;s simply because &lt;code&gt;string::find&lt;/code&gt; solves that problem.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Nancy&lt;/strong&gt; sends us a… different approach to solving this problem.&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-cpp"&gt;&lt;span class="hljs-function"&gt;&lt;span class="hljs-type"&gt;bool&lt;/span&gt; &lt;span class="hljs-title"&gt;substringInString&lt;/span&gt;&lt;span class="hljs-params"&gt;(string str, string::iterator &amp;amp;it)&lt;/span&gt;
&lt;/span&gt;{
  string tmp;
  &lt;span class="hljs-type"&gt;bool&lt;/span&gt; result = &lt;span class="hljs-literal"&gt;false&lt;/span&gt;;
  &lt;span class="hljs-type"&gt;int&lt;/span&gt; size = str.&lt;span class="hljs-built_in"&gt;length&lt;/span&gt;();

  &lt;span class="hljs-type"&gt;int&lt;/span&gt; count = &lt;span class="hljs-number"&gt;0&lt;/span&gt;;
  &lt;span class="hljs-keyword"&gt;while&lt;/span&gt; (count &amp;lt; size)
  {
    tmp += *it;
    it++;
    count++;
    &lt;span class="hljs-keyword"&gt;if&lt;/span&gt; (tmp.&lt;span class="hljs-built_in"&gt;find&lt;/span&gt;(str) != string::npos)
    {
      result = &lt;span class="hljs-literal"&gt;true&lt;/span&gt;;
      it -= size;
      &lt;span class="hljs-keyword"&gt;break&lt;/span&gt;;
    }
  }

  &lt;span class="hljs-keyword"&gt;if&lt;/span&gt; ( !result)
  {
    it -= size;
  }

  &lt;span class="hljs-keyword"&gt;return&lt;/span&gt; result;
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;This function iterates across a string, character by character. In this iteration, we copy one character at a time into &lt;code&gt;tmp&lt;/code&gt;. Then we see if &lt;code&gt;tmp&lt;/code&gt; contains our search &lt;code&gt;str&lt;/code&gt;. If it does, we break out of the loop after rewinding the iterator. Outside of the loop, we check if we found the substring, and if we did, we rewind the iterator. Then we return true or false based on whether on not we found the substring.&lt;/p&gt;
&lt;p&gt;So wait a second. &lt;code&gt;str&lt;/code&gt; is our search string. &lt;code&gt;it&lt;/code&gt; is where we&amp;#39;re searching. And we copy from &lt;code&gt;it&lt;/code&gt; up to our search string&amp;#39;s &lt;code&gt;length&lt;/code&gt; into a temporary string. We then do a &lt;code&gt;find&lt;/code&gt; in that temporary string- hey! This is just a &lt;code&gt;startsWith&lt;/code&gt; check written in the most insane way possible.&lt;/p&gt;
&lt;p&gt;Why even bother with the while loop? While &lt;code&gt;tmp&lt;/code&gt; is shorter than the search string, the answer is always &amp;#34;no, we haven&amp;#39;t found it&amp;#34;. And the developers knew that- that&amp;#39;s why they always rewind &lt;code&gt;size&lt;/code&gt; characters on the iterator. They&amp;#39;re always searching exactly that many characters. Of course, since we &lt;em&gt;always&lt;/em&gt; rewind the same amount, we can also just move the &lt;code&gt;it -= size&lt;/code&gt; statement out of the loop and out of the &lt;code&gt;if&lt;/code&gt; statement and do it once.&lt;/p&gt;
&lt;p&gt;Nancy calls this &amp;#34;a little gem&amp;#34; in a &amp;#34;large codebase&amp;#34;. Yeah, &lt;a href="https://classicgems.net/gem_francevillite.htm"&gt;a real gem&lt;/a&gt;.&lt;/p&gt;
&lt;!-- Easy Reader Version: Undoing the operation you do in the function is a *kind* of constness. --&gt;&lt;div&gt;
	[Advertisement] &lt;b&gt;Plan Your .NET 9 Migration with Confidence&lt;/b&gt;&lt;br/&gt;Your journey to .NET 9 is more than just one decision.Avoid migration migraines with the advice in this free guide. &lt;b&gt;&lt;a href="https://inedo.com/support/whitepapers/dotnet-guide?utm_campaign=dotnet&amp;amp;utm_source=tdwtf-footer"&gt;Download Free Guide Now!&lt;/a&gt;&lt;/b&gt;
&lt;/div&gt;
&lt;div style="clear: left;"&gt; &lt;/div&gt;</description><slash:comments>11</slash:comments><wfw:comment>https://thedailywtf.com/articles/comments/please-find-rewind</wfw:comment></item><item><dc:creator>Remy Porter</dc:creator><title>CodeSOD: Not for Nullthing</title><link>https://thedailywtf.com/articles/not-for-nullthing</link><category>CodeSOD</category><pubDate>Tue, 05 May 2026 06:30:00 GMT</pubDate><guid>https://thedailywtf.com/articles/not-for-nullthing</guid><description>&lt;p&gt;Today&amp;#39;s anonymous submitter sends us some code that just makes your mind go… blank when you look at it.&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-java"&gt;	&lt;span class="hljs-keyword"&gt;public&lt;/span&gt; &lt;span class="hljs-keyword"&gt;static&lt;/span&gt; &lt;span class="hljs-type"&gt;boolean&lt;/span&gt; &lt;span class="hljs-title function_"&gt;isNull&lt;/span&gt;&lt;span class="hljs-params"&gt;(String value)&lt;/span&gt; {
		&lt;span class="hljs-keyword"&gt;return&lt;/span&gt; StringUtils.isBlank(value);
	}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;code&gt;StringUtils.isBlank&lt;/code&gt; comes from the Apache Commons library. It&amp;#39;s a helper function for Java which returns true if a string is, well, &lt;em&gt;blank&lt;/em&gt;. &amp;#34;Blank&amp;#34; in this case is: empty, null, or only whitespace. So it&amp;#39;s important to note that &lt;code&gt;isBlank&lt;/code&gt; may return &lt;code&gt;true&lt;/code&gt; on a &lt;code&gt;null&lt;/code&gt;, but it &lt;em&gt;isn&amp;#39;t&lt;/em&gt; truly a null-check, so wrapping it in &lt;code&gt;isNull&lt;/code&gt; is just confusing.&lt;/p&gt;
&lt;p&gt;But imagine I&amp;#39;ve got another problem. Let&amp;#39;s say I have a database that&amp;#39;s been poorly normalized and maintained. And so I have a bunch of fields that maybe are &lt;code&gt;null&lt;/code&gt;, but some also maybe contain the &lt;em&gt;string&lt;/em&gt; &lt;code&gt;&amp;#34;null&amp;#34;&lt;/code&gt;. What am I going to do then? I need another function.&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-java"&gt;	&lt;span class="hljs-keyword"&gt;public&lt;/span&gt; &lt;span class="hljs-keyword"&gt;static&lt;/span&gt; &lt;span class="hljs-type"&gt;boolean&lt;/span&gt; &lt;span class="hljs-title function_"&gt;isNullAndNull&lt;/span&gt;&lt;span class="hljs-params"&gt;(String value)&lt;/span&gt; {
		&lt;span class="hljs-keyword"&gt;return&lt;/span&gt; isNull(value) &amp;amp;&amp;amp; &lt;span class="hljs-string"&gt;&amp;#34;null&amp;#34;&lt;/span&gt;.equalsIgnoreCase(value);
	}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Ah yes, &lt;code&gt;isNullAndNull&lt;/code&gt;, the clearest and easiest name I could imagine for this. It tells me exactly what the function is checking: is it null, and is it also null? We add a second check to our &lt;code&gt;isNull&lt;/code&gt; call- we check if the input value matches the string &lt;code&gt;&amp;#34;null&amp;#34;&lt;/code&gt;. Except we&amp;#39;re &lt;code&gt;&amp;amp;&amp;amp;&lt;/code&gt;ing the conditions together. So this function will always return false. It can&amp;#39;t both be blank &lt;em&gt;and&lt;/em&gt; contain the string &lt;code&gt;&amp;#34;null&amp;#34;&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;Which means Jennifer Null, &lt;a href="https://www.bbc.com/future/article/20160325-the-names-that-break-computer-systems"&gt;who is a real person&lt;/a&gt;, can breathe easy. This version of a null check won&amp;#39;t think she&amp;#39;s nothing.&lt;/p&gt;
&lt;!-- Easy Reader Version: isNullAndNull is some fever dream function naming. It sounds like LLM stuff, but I don't think an LLM would have made the "&amp;&amp;" mistake here. --&gt;&lt;div&gt;
	[Advertisement] Picking up &lt;b&gt;NuGet&lt;/b&gt; is easy. Getting good at it takes time. &lt;a href="https://inedo.com/support/whitepapers/nuget-guide?utm_source=tdwtf&amp;amp;utm_medium=Footerad&amp;amp;utm_campaign=nuget"&gt;Download our guide to learn the best practice of NuGet for the Enterprise.&lt;/a&gt;

&lt;/div&gt;
&lt;div style="clear: left;"&gt; &lt;/div&gt;</description><slash:comments>13</slash:comments><wfw:comment>https://thedailywtf.com/articles/comments/not-for-nullthing</wfw:comment></item><item><dc:creator>Remy Porter</dc:creator><title>Empty Pockets</title><link>https://thedailywtf.com/articles/empty-pockets</link><category>Feature Articles</category><pubDate>Mon, 04 May 2026 06:30:00 GMT</pubDate><guid>https://thedailywtf.com/articles/empty-pockets</guid><description>&lt;p&gt;If you&amp;#39;ve seen one developer recounting how their AI agent deleted production, you&amp;#39;ve seen them all. They&amp;#39;re mostly not interesting stories. It&amp;#39;s like watching someone speeding through traffic on a motorcycle without a helmet: the eventual tragedy is sad, but it&amp;#39;s unsurprising and not an interesting story to tell. It&amp;#39;s not even interesting as a warning: the kind of person who speeds on a motorcycle without a helmet isn&amp;#39;t doing so because they don&amp;#39;t understand the danger. They&amp;#39;ve just decided it doesn&amp;#39;t apply to them.&lt;/p&gt;
&lt;p&gt;But the founder of PocketOS, Jer, &lt;a href="https://x.com/lifeof_jer/status/2048103471019434248"&gt;recently shared&lt;/a&gt; how- whoopsie!- their AI agent deleted production. There&amp;#39;s a lot of ingredients that go into this particular disaster, which I think makes it interesting, because the use of a poorly supervised AI agent is only &lt;em&gt;one&lt;/em&gt; ingredient in this absolute trainwreck of a story.&lt;/p&gt;
&lt;p&gt;PocketOS is a small company that makes software for rental companies to manage reservations. Car rentals are a big customer, but the tool is more general than that. They manage all of their infrastructure via a service called Railway. Railway is a pretty-looking GUI tool for automating your deployments and the target environments.&lt;/p&gt;
&lt;p&gt;PocketOS &lt;em&gt;also&lt;/em&gt; is heavily adopting Cursor wrapping around the Claude model. They&amp;#39;ve paid big bucks for the top-end model offered. Many of their components, like Railway, offer &lt;abbr title="Model Context Protocol"&gt;MCP&lt;/abbr&gt; services so that their LLM can do useful things. They&amp;#39;re using the Claude LLM to automate as much as they can.&lt;/p&gt;
&lt;p&gt;So far, this is all a pretty typical setup. They pointed Claude at their code and gave it a &amp;#34;routine&amp;#34; task, and sent it to work. It toddled through the problem and encountered a credential issue. It &amp;#34;decided&amp;#34; that the fix for this issue was to delete a storage volume and recreate it. It scanned through the code to find a file containing an API key, found it, and then sent a &lt;code&gt;POST&lt;/code&gt; request via cURL to delete the volume in question.&lt;/p&gt;
&lt;p&gt;Jer writes:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;To execute the deletion, the agent went looking for an API token. It found one in a file completely unrelated to the task it was working on. That token had been created for one purpose: to add and remove custom domains via the Railway CLI for our services. We had no idea — and Railway&amp;#39;s token-creation flow gave us no warning — that the same token had blanket authority across the entire Railway GraphQL API, including destructive operations like volumeDelete. Had we known a CLI token created for routine domain operations could also delete production volumes, we would never have stored it.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Wait, the tokens you create in Railway all have god-level privileges? That sounds like a terrible idea. And you were storing the token in your code? We&amp;#39;ll come back to this in a moment, but sure, this is bad, but you can just restore from backup, right?&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;The volume was deleted. Because Railway stores volume-level backups in the same volume — a fact buried in their own documentation that says &amp;#34;wiping a volume deletes all backups&amp;#34; — those went with it. Our most recent recoverable backup was three months old.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Oh. Oh no.&lt;/p&gt;
&lt;p&gt;Now, I don&amp;#39;t think it&amp;#39;s literally true that Railway is storing your backups &lt;em&gt;literally&lt;/em&gt; in the same volume as the thing they&amp;#39;re backing up. I certainly hope not. But they &lt;em&gt;do&lt;/em&gt;  apparently delete your backups when you delete the volume associated with them. Which is a choice, certainly. A bad one. And one that they &lt;em&gt;documented&lt;/em&gt;, according to Jer. It was, in his words, &amp;#34;buried&amp;#34; in the docs.&lt;/p&gt;
&lt;p&gt;But let&amp;#39;s go back to the tokens for a moment. I am not a Railway user, but I checked out the tool and went through the process of creating a project token. And while no, Railway does not give you big red flags warning you &amp;#34;Hey, this token can do ABSOLUTELY ANYTHING&amp;#34;, it also &lt;em&gt;never gives you an opportunity to scope the token&lt;/em&gt;. Which, I don&amp;#39;t know about you, but the first thing I do when I create an authentication entity is try and figure out how to control its authorizations, because I assume at the start &lt;em&gt;it doesn&amp;#39;t have any&lt;/em&gt;. That&amp;#39;d be sane.&lt;/p&gt;
&lt;p&gt;The scoping happens when you create the token, depending on what context you&amp;#39;re in when you do it. It&amp;#39;s only a handful of scopes, and no fine grained permissions on API keys at all. The lowest level is &amp;#34;Project&amp;#34; which can do anything to a single environment- which does mean that even if you, like Jer&amp;#39;s team, wanted to have a script that changed some DNS settings in production, that same key could be used to delete volumes in production. Which means you really &lt;em&gt;really&lt;/em&gt; want to take care of that key, and you certainly don&amp;#39;t want to leave it where some junior developer or bumbling AI agent can find it.&lt;/p&gt;
&lt;p&gt;Jer also complains that Railway shouldn&amp;#39;t allow an API call to take destructive actions without more protections, like forcing someone to type in the name of the thing being deleted or sending a confirmation email, or something. This, I&amp;#39;m more skeptical of. Most cloud providers &lt;em&gt;don&amp;#39;t&lt;/em&gt; offer anything like this in their APIs, at least that I&amp;#39;ve seen, because on a certain level, if you&amp;#39;re invoking the API with the proper credentials, that&amp;#39;s a big enough hill to climb that we can assume you&amp;#39;ve intended your action. The correct way to protect against this is properly scoped keys &lt;em&gt;and keeping those keys secure and not just lying around in plain text&lt;/em&gt;. There&amp;#39;s a certain aspect of understanding that you&amp;#39;re using a potentially dangerous tool and need to take the responsibility for safety into your own hands; while a table saw can easily take some fingers off, it&amp;#39;s perfectly safe &lt;em&gt;when used correctly&lt;/em&gt;.&lt;/p&gt;
&lt;p&gt;This is all bad, but how can we make it worse? Well, Jer demanded that Claude &amp;#34;explain itself&amp;#34;. In a section called &amp;#34;The Agent&amp;#39;s Confession&amp;#34;, Jer highlights that the agent is able to identify the explict rules that it failed to follow.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Read that again. The agent itself enumerates the safety rules it was given and admits to violating every one. This is not me speculating about agent failure modes. This is the agent on the record, in writing.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;No, it is &lt;em&gt;not&lt;/em&gt; the agent on record. I see this kind of thing a lot when people talk about LLMs. An LLM cannot explain its reasoning. It cannot go on &amp;#34;the record&amp;#34;. It cannot confess to anything. While what it plops out when asked might be &lt;em&gt;interesting&lt;/em&gt;, it is not &lt;em&gt;an explanation&lt;/em&gt;. The only explanation is that it&amp;#39;s a powerful statistical model trying to create a plausible string of tokens! It&amp;#39;s simply looking at its context window and your prompt and trying to predict what it should say. It can tell you what rules it violated not because it understands the rules or knows it violated any rules, but because those rules are in its context window. If you ask it right, it&amp;#39;ll confess to killing JFK and framing Oswald for the crime.&lt;/p&gt;
&lt;p&gt;Jer then tries to ensure that Cursor takes some of the blame, pointing to Cursor&amp;#39;s &amp;#34;guardrails&amp;#34; &lt;a href="https://cursor.com/docs/agent/security"&gt;documentation&lt;/a&gt;. Except, here, the documentation is actually quite explicit about what those guardrails guarantee. If you&amp;#39;re using a first-party tool, it will prohibit unsafe operations. When using 3rd party MCPs, like Railway&amp;#39;s, the only guardrail is that it requires human approval for every action- unless you update your allowlist for that MCP. If you put them in your allowlist, &lt;em&gt;the guardrails go away&lt;/em&gt;. Jer argues that tools should enforce more protection against LLM behaviors, but the problem with that is people- like the PocketOS team- &lt;em&gt;turn those protections off&lt;/em&gt;. And like a lot of safety mistakes, they can get away with it all the way up until the point where they can&amp;#39;t.&lt;/p&gt;
&lt;p&gt;Jer follows this by listing off a pile of other times using Cursor has caused disasters, which isn&amp;#39;t making the argument he thinks it is: yes, Cursor is dangerous, &lt;em&gt;but those dangers are well known&lt;/em&gt;. It makes the choice to turn Cursor loose without strict supervision seem even more foolish.&lt;/p&gt;
&lt;p&gt;Jer writes:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;For now I want this incident understood on its own terms: as a Cursor failure, a Railway failure, and a backup-architecture failure that all happened to one company in one Friday afternoon.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;It&amp;#39;s &lt;em&gt;also&lt;/em&gt; a PocketOS failure. It&amp;#39;s a failure to properly assess the tools and environments you chose to use for your product. A failure to read and understand the docs for vital features, like *backups*. A failure to employ even the most basic safeguards. A failure to put a second&amp;#39;s thought into key management- even if that key was &lt;em&gt;only&lt;/em&gt; for DNS entries, you &lt;em&gt;still&lt;/em&gt; shouldn&amp;#39;t chuck it in source control. A failure to have a competent backup strategy. It&amp;#39;s worth noting that they &lt;em&gt;did&lt;/em&gt; restore from a three month old backup, which means &lt;em&gt;they were at one point&lt;/em&gt; taking backups outside of Railway&amp;#39;s volume setup. That was a wise decision. That they stopped is a failure.&lt;/p&gt;
&lt;p&gt;The first rule of disaster retrospectives is that it&amp;#39;s never one piece that&amp;#39;s the failure. It&amp;#39;s never one person&amp;#39;s fault, one tool&amp;#39;s fault, one vendor&amp;#39;s fault. It&amp;#39;s a systemic failure. Railway&amp;#39;s keys should be finer grained. But also, you shouldn&amp;#39;t leave keys lying around. Deleting backups when you delete the volume is a terrible idea, but having only one service for backups (that&amp;#39;s also your primary site) is a terrible idea. Claude&amp;#39;s ability to enforce its own guardrails should be better, but LLMs are notoriously dangerous about this: &lt;em&gt;you should know better&lt;/em&gt;, and by your own words &lt;em&gt;you did&lt;/em&gt;.&lt;/p&gt;
&lt;p&gt;This is not an anti-AI post, or even a &amp;#34;get a load of this asshole&amp;#34; post. &lt;!-- okay, it's a LITTLE BIT a "get a load of this asshole" post --&gt; It is a &amp;#34;understand the damn tools you&amp;#39;re using&amp;#34; post. Be critical of them. Don&amp;#39;t trust them. Ever. Especially LLMs, because the worst part of an LLM is that it takes away the one thing computers used to be good at: predictable, deterministic behavior. But not just LLMs: don&amp;#39;t trust your cloud provider, don&amp;#39;t trust your infrastructure manager. Dig into them and understand how they work, and if they seem to complicated to understand, than they may be too complicated to trust.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Update&lt;/strong&gt;: As pointed out in the featured comment below, Railway did finally get a backup restored. So they got their data back. Yay? From the post, Jer remains committed to making this a Railway issue and not a PocketOS issue.&lt;/p&gt;
&lt;!-- Easy Reader Version: The really fun part is Jer complaining that the CEO of Railway hasn't so much as called him. The entitlement, man. --&gt;&lt;div&gt;
	[Advertisement] Picking up &lt;b&gt;NuGet&lt;/b&gt; is easy. Getting good at it takes time. &lt;a href="https://inedo.com/support/whitepapers/nuget-guide?utm_source=tdwtf&amp;amp;utm_medium=Footerad&amp;amp;utm_campaign=nuget"&gt;Download our guide to learn the best practice of NuGet for the Enterprise.&lt;/a&gt;

&lt;/div&gt;
&lt;div style="clear: left;"&gt; &lt;/div&gt;</description><slash:comments>34</slash:comments><wfw:comment>https://thedailywtf.com/articles/comments/empty-pockets</wfw:comment></item><item><dc:creator>Lyle Seaman</dc:creator><title>Error'd: Parametric Projection</title><link>https://thedailywtf.com/articles/parametric-projection</link><category>Error'd</category><pubDate>Fri, 01 May 2026 06:30:00 GMT</pubDate><guid>https://thedailywtf.com/articles/parametric-projection</guid><description>&lt;strong&gt;Roger C.&lt;/strong&gt; gets on second base with an unforced error.  &amp;#34;Not only is the content too large, the error message informing us of this is also too large to fit the visible space. A layered, double WTF.&amp;#34;
&lt;p&gt;&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;a href="#782b1790d9d549d6a8acf4045669d7a6"&gt;&lt;img itemprop="image" border="0" alt="782b1790d9d549d6a8acf4045669d7a6" src="https://d3hvi6t161kfmf.cloudfront.net/images/2026/04/19/782b1790d9d549d6a8acf4045669d7a6.jpeg"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;/blockquote&gt;


&lt;p&gt;&amp;#34;AWS Spellcheck Fail!&amp;#34; alerts
&lt;strong&gt;Peter&lt;/strong&gt;
&amp;#34;If only someone at AWS knew the correct paramters to
activate the spellcheck.&amp;#34;
&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;a href="#ee85e87fd7cb4cc2ac3038cb9f97ccf8"&gt;&lt;img itemprop="image" border="0" alt="ee85e87fd7cb4cc2ac3038cb9f97ccf8" src="https://d3hvi6t161kfmf.cloudfront.net/images/2026/04/19/ee85e87fd7cb4cc2ac3038cb9f97ccf8.png"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;/blockquote&gt;


&lt;p&gt;&amp;#34;How long is too long for a job to be open? &amp;#34; wonders
&lt;strong&gt;Lincoln K.&lt;/strong&gt;
&amp;#34;I didn&amp;#39;t even know LinkedIn existed 61 years ago, let
alone was accepting postings... Though only 81 applicants in that
time is hardly an impressive turn-out.&amp;#34; For a &amp;#34;Vice President Operations and Quality Control&amp;#34;, no less.
&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;a href="#1c3d4b06a37e4119b62dc39bad29b9a3"&gt;&lt;img itemprop="image" border="0" alt="1c3d4b06a37e4119b62dc39bad29b9a3" src="https://d3hvi6t161kfmf.cloudfront.net/images/2026/04/19/1c3d4b06a37e4119b62dc39bad29b9a3.jpeg"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;/blockquote&gt;


&lt;p&gt;An anonymous Richard reports 
&amp;#34;This came through my door. On a card that, in order to get to my door, had my full address printed on it, including my &lt;area/&gt;.&amp;#34;

&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;a href="#9df5e07d210846f08dc925105f19b64b"&gt;&lt;img itemprop="image" border="0" alt="9df5e07d210846f08dc925105f19b64b" src="https://d3hvi6t161kfmf.cloudfront.net/images/2026/04/19/9df5e07d210846f08dc925105f19b64b.jpeg"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;/blockquote&gt;


&lt;p&gt;Oenophile Abroad
&lt;strong&gt;Michael R.&lt;/strong&gt; shares 
&amp;#34;My Macbook broke after being &amp;#34;exposed&amp;#34; to red wine. As
a German in London it pleases me so see that
the repair shop offers this time granularity.&amp;#34;
&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;a href="#a9f634b888de4927babb91d7d2920579"&gt;&lt;img itemprop="image" border="0" alt="a9f634b888de4927babb91d7d2920579" src="https://d3hvi6t161kfmf.cloudfront.net/images/2026/04/19/a9f634b888de4927babb91d7d2920579.png"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;/blockquote&gt;

&lt;div&gt;
	&lt;img src="https://thedailywtf.com/images/inedo/proget-icon.png" style="display:block; float: left; margin: 0 10px 10px 0;"/&gt; [Advertisement] 
	Keep all your packages and Docker containers in one place, scan for vulnerabilities, and control who can access different feeds. ProGet installs in minutes and has a powerful free version with a lot of great features that you can upgrade when ready.&lt;a href="https://inedo.com/proget?utm_source=tdwtf&amp;amp;utm_medium=footer&amp;amp;utm_content=PlebsFooter"&gt;Learn more.&lt;/a&gt;
&lt;/div&gt;
&lt;div style="clear: left;"&gt; &lt;/div&gt;
</description><slash:comments>7</slash:comments><wfw:comment>https://thedailywtf.com/articles/comments/parametric-projection</wfw:comment></item><item><dc:creator>Remy Porter</dc:creator><title>CodeSOD: Cancel Catch</title><link>https://thedailywtf.com/articles/cancel-catch</link><category>CodeSOD</category><pubDate>Thu, 30 Apr 2026 06:30:00 GMT</pubDate><guid>https://thedailywtf.com/articles/cancel-catch</guid><description>&lt;p&gt;&amp;#34;This WTF is in Matlab&amp;#34; almost feels like cheating. At one place I worked, somebody&amp;#39;s job was struggling through a mountain of Matlab code and porting it into C. &amp;#34;This Matlab code looks like it was written by an alien,&amp;#34; also doesn&amp;#39;t really get much traction- &lt;em&gt;all&lt;/em&gt; Matlab code looks like it was written by an alien. This falls into the realm of &amp;#34;Researchers use Matlab, researchers may be very smart about their domain, but generally don&amp;#39;t know the first thing about writing maintainable code, because that&amp;#39;s not their job.&amp;#34;&lt;/p&gt;
&lt;p&gt;But let&amp;#39;s take a look at some MatLab &lt;strong&gt;Carl W&lt;/strong&gt; found:&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-matlab"&gt;    &lt;span class="hljs-keyword"&gt;try&lt;/span&gt;
        &lt;span class="hljs-keyword"&gt;if&lt;/span&gt; (~&lt;span class="hljs-built_in"&gt;isempty&lt;/span&gt;(fieldnames(bigStruct)) &amp;amp;&amp;amp; isfield(bigStruct,&lt;span class="hljs-string"&gt;&amp;#39;pathName&amp;#39;&lt;/span&gt;))
            [FileName, PathName] = uigetfile(bigStruct.pathName);
        &lt;span class="hljs-keyword"&gt;else&lt;/span&gt;
            [FileName, PathName] = uigetfile(lastPath); &lt;span class="hljs-comment"&gt;%lastPath holds previous path&lt;/span&gt;
        &lt;span class="hljs-keyword"&gt;end&lt;/span&gt;
    &lt;span class="hljs-keyword"&gt;catch&lt;/span&gt;
        bigStruct = struct;
    &lt;span class="hljs-keyword"&gt;end&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The &lt;code&gt;uigetfile&lt;/code&gt; function opens a file dialog box. When the user selects a file, &lt;code&gt;FileName&lt;/code&gt; holds the filename, &lt;code&gt;PathName&lt;/code&gt; holds the containing path. If the user doesn&amp;#39;t select a valid file, or clicks &amp;#34;Cancel&amp;#34;, both of those variables get set to &lt;code&gt;0&lt;/code&gt;. It&amp;#39;s then up to the caller to check the return value and decide what happens next.&lt;/p&gt;
&lt;p&gt;Which is not what happens here, obviously. The developer responsible seems to believe that it maybe throws an exception? And they can just catch it? Carl&amp;#39;s best guess is that this is a &amp;#34;weird&amp;#34; way to catch the cancel button. But it does mean that &lt;code&gt;FileName&lt;/code&gt; and &lt;code&gt;PathName&lt;/code&gt; get set to &lt;code&gt;0&lt;/code&gt;, and those zeros propagate until something finally tries to open those files, at which point everything blows up and the user doesn&amp;#39;t know why.&lt;/p&gt;
&lt;!-- Easy Reader Version: Look, I agree that index from 1 is a more "human" way of talking about arrays, but 0 is too ingrained in my brain and it feels wrong every time. --&gt;&lt;div&gt;
	[Advertisement] &lt;b&gt;Plan Your .NET 9 Migration with Confidence&lt;/b&gt;&lt;br/&gt;Your journey to .NET 9 is more than just one decision.Avoid migration migraines with the advice in this free guide. &lt;b&gt;&lt;a href="https://inedo.com/support/whitepapers/dotnet-guide?utm_campaign=dotnet&amp;amp;utm_source=tdwtf-footer"&gt;Download Free Guide Now!&lt;/a&gt;&lt;/b&gt;
&lt;/div&gt;
&lt;div style="clear: left;"&gt; &lt;/div&gt;</description><slash:comments>16</slash:comments><wfw:comment>https://thedailywtf.com/articles/comments/cancel-catch</wfw:comment></item><item><dc:creator>Ellis Morning</dc:creator><title>A Whale of a Problem</title><link>https://thedailywtf.com/articles/a-whale-of-a-problem</link><category>Feature Articles</category><pubDate>Wed, 29 Apr 2026 06:30:00 GMT</pubDate><guid>https://thedailywtf.com/articles/a-whale-of-a-problem</guid><description>&lt;p&gt;From our &lt;b&gt;Anonymous&lt;/b&gt; submitter:&lt;/p&gt;

&lt;blockquote&gt;&lt;p&gt;Our company creates graphs to visualize data.  We have many small fish customers, but we have one whale who uses our product that is 90% of company revenue. (WTF number 1.)&lt;/p&gt;

&lt;p&gt;So if he is not happy, it&amp;#39;s all-hands-on deck-mode.&lt;/p&gt; 

&lt;p&gt;He complained that our APIs and charts are loading slowly for him.
For 3 weeks, we&amp;#39;ve tried a TON of optimizations, including WTF 2: spinning up a special server he alone can hit.&lt;/p&gt;

&lt;p&gt;Today, we found out that he&amp;#39;s always complaining when he&amp;#39;s in his car, driving from home to the office. But since he &amp;#34;totally has the best wifi money can buy,&amp;#34; that isn&amp;#39;t worth investigating.&lt;/p&gt;

&lt;p&gt;WTF 3: thinking wifi and data are always 100% reliable in a car driving around.&lt;/p&gt;&lt;/blockquote&gt;

&lt;p style="float:right; padding-left:10px; padding-bottom:10px;"&gt;&lt;a title="Giles Laurent, CC BY-SA 4.0 &amp;lt;https://creativecommons.org/licenses/by-sa/4.0&amp;gt;, via Wikimedia Commons" href="hhttps://upload.wikimedia.org/wikipedia/commons/thumb/b/ba/001_Humpback_whale_breaching_in_Ballena_Marine_National_Park_Photo_by_Giles_Laurent.jpg/330px-001_Humpback_whale_breaching_in_Ballena_Marine_National_Park_Photo_by_Giles_Laurent.jpg"&gt;&lt;img itemprop="image" width="300" alt="Humpback whale breaching in Ballena Marine National Park" src="https://upload.wikimedia.org/wikipedia/commons/thumb/b/ba/001_Humpback_whale_breaching_in_Ballena_Marine_National_Park_Photo_by_Giles_Laurent.jpg/330px-001_Humpback_whale_breaching_in_Ballena_Marine_National_Park_Photo_by_Giles_Laurent.jpg"/&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Our submitter highlights one of the major pitfalls of the so-called &lt;a href="https://jonathanstark.com/daily/20171004-what-to-do-about-your-whale-problem"&gt;whale client&lt;/a&gt;: if they&amp;#39;re a &lt;i&gt;bad&lt;/i&gt; client, you&amp;#39;re in for an extra-bad time.&lt;/p&gt;

&lt;p&gt;As I lean harder into freelancing, I&amp;#39;m learning to scan the waters ahead of me for potential whales. My goal is to build up multiple small, diverse income streams, because I&amp;#39;ve had my own dangerous encounters with whales in the past.&lt;/p&gt;

&lt;p&gt;At one employer of mine, there was Facebook, who acted as if they were our new &lt;i&gt;owners&lt;/i&gt; rather than a new customer. They&amp;#39;d already produced flashy marketing videos of the sorts of solutions they planned to implement with our software, showing people delighted with the results. In meetings, these things were talked up as amazing game-changers. Meanwhile, I found all the things Facebook wanted to do horribly creepy and invasive.&lt;/p&gt;

&lt;p&gt;Even worse, Facebook began dictating how our award-winning technical support should change to accommodate their whims, up to and including having a dedicated toady—er, support rep—who did nothing but field Facebook-related tickets, similar to a technical account manager (TAM).&lt;/p&gt;

&lt;p&gt;That was the last straw for me. I left that company before I was forced to deal with any of Facebook&amp;#39;s crap.&lt;/p&gt;

&lt;p&gt;My second whale sighting occurred at a startup that&amp;#39;d landed Porsche, far and away their biggest client ever. All of a sudden, our timeline for adding new features and fixing bugs became Porsche&amp;#39;s honey-do list. All of a sudden, the platform frequently crashed and became unusable for everyone because it couldn&amp;#39;t handle the amount of traffic Porsche (and their clients) hurled at it.&lt;/p&gt;

&lt;p&gt;On the other hand, there were several times in that startup&amp;#39;s existence when a big wad of promised funding failed to materialize. Porsche kept the business afloat and literally kept my lights on.&lt;/p&gt;

&lt;p&gt;I find it less than ideal to be at any company&amp;#39;s mercy. I want a world that would neither spawn whales nor millions of startups named Sploink, Dink, and Twangle that promise to bring the power of AI to your dinner fork.&lt;/p&gt;

&lt;p&gt;&lt;b&gt;Have your own epic whaling adventures? Share with us in the comments!&lt;/b&gt;&lt;/p&gt;&lt;div&gt;
	&lt;img src="https://thedailywtf.com/images/inedo/buildmaster-icon.png" style="display:block; float: left; margin: 0 10px 10px 0;"/&gt; [Advertisement] 
	&lt;a href="https://inedo.com/BuildMaster?utm_source=tdwtf&amp;amp;utm_medium=footerad&amp;amp;utm_term=2018&amp;amp;utm_content=Confidence&amp;amp;utm_campaign=Buildmaster_Footer"&gt;Utilize BuildMaster&lt;/a&gt; to release your software with confidence, at the pace your business demands. &lt;a href="https://inedo.com/BuildMaster/download?utm_source=tdwtf&amp;amp;utm_medium=footerad&amp;amp;utm_term=2018&amp;amp;utm_content=Confidence&amp;amp;utm_campaign=Buildmaster_Footer"&gt;Download&lt;/a&gt; today!  
&lt;/div&gt;
&lt;div style="clear: left;"&gt; &lt;/div&gt;
</description><slash:comments>20</slash:comments><wfw:comment>https://thedailywtf.com/articles/comments/a-whale-of-a-problem</wfw:comment></item><item><dc:creator>Remy Porter</dc:creator><title>CodeSOD: Lint Brush Off</title><link>https://thedailywtf.com/articles/lint-brush-off</link><category>CodeSOD</category><pubDate>Tue, 28 Apr 2026 06:30:00 GMT</pubDate><guid>https://thedailywtf.com/articles/lint-brush-off</guid><description>&lt;p&gt;A few years back, C# added the concept of &amp;#34;primary constructors&amp;#34;. Instead of declaring the storage for class members and then initializing them in the constructor, you can annotate the class itself with the required fields, and C# automatically generates a constructor for you. It&amp;#39;s all very TypeScript and very Microsoft, and certainly cuts down on some boilerplate. &lt;!-- My instinct is to dislike it, more on the chosen syntax than the actual idea, but I'm not doing much C# these days, so whatever --&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Esben B&lt;/strong&gt;&amp;#39;s team isn&amp;#39;t really using them in many places, but they are using a linter which is opinionated about them. So this in-line constructor causes the linter to complain:&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-csharp"&gt;    &lt;span class="hljs-function"&gt;&lt;span class="hljs-keyword"&gt;public&lt;/span&gt; &lt;span class="hljs-title"&gt;DocumentNetworkController&lt;/span&gt;(&lt;span class="hljs-params"&gt;ILookupClient service&lt;/span&gt;)
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The linter wants you to switch this to a primary constructor. Esben didn&amp;#39;t want to do that, and didn&amp;#39;t want to change the global linter configuration, and so added a pragma to disable that particular warning:&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-csharp"&gt;&lt;span class="hljs-meta"&gt;#&lt;span class="hljs-keyword"&gt;pragma&lt;/span&gt; &lt;span class="hljs-keyword"&gt;warning&lt;/span&gt; disable IDE0290 // Use primary constructor&lt;/span&gt;
    &lt;span class="hljs-function"&gt;&lt;span class="hljs-keyword"&gt;public&lt;/span&gt; &lt;span class="hljs-title"&gt;DocumentNetworkController&lt;/span&gt;(&lt;span class="hljs-params"&gt;ILookupClient service&lt;/span&gt;)
#pragma warning restore IDE0290
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The linter didn&amp;#39;t like this. It threw a new warning: that this suppression wasn&amp;#39;t needed. Which was news to Esben, as clearly the suppression &lt;em&gt;was&lt;/em&gt; needed if you wanted to make the warnings go away. The obvious solution was to disable the warning that you didn&amp;#39;t need to disable the warning:&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-csharp"&gt;&lt;span class="hljs-meta"&gt;#&lt;span class="hljs-keyword"&gt;pragma&lt;/span&gt; &lt;span class="hljs-keyword"&gt;warning&lt;/span&gt; disable IDE0079, IDE0290 // Use primary constructor&lt;/span&gt;
    &lt;span class="hljs-function"&gt;&lt;span class="hljs-keyword"&gt;public&lt;/span&gt; &lt;span class="hljs-title"&gt;DocumentNetworkController&lt;/span&gt;(&lt;span class="hljs-params"&gt;ILookupClient service&lt;/span&gt;)
#pragma warning restore IDE0290, IDE0079
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Except this doesn&amp;#39;t work. These pragmas take effect on the next line, which means you can&amp;#39;t disable &lt;code&gt;IDE0079&lt;/code&gt; on the same line as &lt;code&gt;IDE0290&lt;/code&gt; and expect it to work. Which means the final version of the code looked like this:&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-csharp"&gt;&lt;span class="hljs-meta"&gt;#&lt;span class="hljs-keyword"&gt;pragma&lt;/span&gt; &lt;span class="hljs-keyword"&gt;warning&lt;/span&gt; disable IDE0079 // Disable &lt;span class="hljs-keyword"&gt;warning&lt;/span&gt; about not needed supression&lt;/span&gt;
&lt;span class="hljs-meta"&gt;#&lt;span class="hljs-keyword"&gt;pragma&lt;/span&gt; &lt;span class="hljs-keyword"&gt;warning&lt;/span&gt; disable IDE0290 // Use primary constructor&lt;/span&gt;
    &lt;span class="hljs-function"&gt;&lt;span class="hljs-keyword"&gt;public&lt;/span&gt; &lt;span class="hljs-title"&gt;DocumentNetworkController&lt;/span&gt;(&lt;span class="hljs-params"&gt;ILookupClient service&lt;/span&gt;)
#pragma warning restore IDE0290, IDE0079
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Esben writes:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;So the nice recommendation to use a primary ctor ended up with 3 lines of annoying boilerplate code. Good times \o/&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;While yes, this is frustrating, I will say there&amp;#39;s an element of &amp;#34;when the table saw keeps taking fingers off, that may be more of a &lt;em&gt;you&lt;/em&gt; problem.&amp;#34; I don&amp;#39;t know the details, so I can&amp;#39;t say, &amp;#34;just change the linter config or adopt its recommendation&amp;#34; and claim that the problem goes away, but when the tool hurts you, it&amp;#39;s a definite sign of one of two things: it&amp;#39;s either the wrong tool, or you&amp;#39;re using it wrong.&lt;/p&gt;
&lt;!-- Easy Reader Version: Linter, it hurts whenever I do this! Then don't do that. --&gt;&lt;div&gt;
	&lt;img src="https://thedailywtf.com/images/inedo/proget-icon.png" style="display:block; float: left; margin: 0 10px 10px 0;"/&gt; [Advertisement] 
	ProGet’s got you covered with security and access controls on your NuGet feeds. &lt;a href="https://inedo.com/proget/private-nuget-server?utm_source=tdwtf&amp;amp;utm_medium=footer&amp;amp;utm_content=GotYouCoveredFooter&amp;amp;utm_campaign=Cyclops2020"&gt;Learn more.&lt;/a&gt;
&lt;/div&gt;
&lt;div style="clear: left;"&gt; &lt;/div&gt;
</description><slash:comments>17</slash:comments><wfw:comment>https://thedailywtf.com/articles/comments/lint-brush-off</wfw:comment></item><item><dc:creator>Remy Porter</dc:creator><title>CodeSOD: The JSON Template</title><link>https://thedailywtf.com/articles/the-json-template</link><category>CodeSOD</category><pubDate>Mon, 27 Apr 2026 06:30:00 GMT</pubDate><guid>https://thedailywtf.com/articles/the-json-template</guid><description>&lt;p&gt;We rip on PHP a lot, but I am willing to admit that the language and ecosystem have evolved over the years. What started as an ugly templating language is now just an ugly regular language.&lt;/p&gt;
&lt;p&gt;But what happens when you still really want to do things with templates? &lt;strong&gt;Allison&lt;/strong&gt; has inherited a Python-based, WSGI application which rejects any sort of formal routing or basic web development best practices. Their way of routing requests is simply long chains of &amp;#34;if condition then invokeA elif otherCondition then invokeB&amp;#34;. Sometimes, those conditions will directly set the MIME type on the HTTP response.&lt;/p&gt;
&lt;p&gt;They do use a templating library called Mako for generating their responses. They use it for their HTML responses, obviously. They also use it for their JSON responses, generating code like this:&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-python"&gt;{
    &lt;span class="hljs-string"&gt;&amp;#34;success&amp;#34;&lt;/span&gt;: true,
    &lt;span class="hljs-string"&gt;&amp;#34;items&amp;#34;&lt;/span&gt;: {
        %&lt;span class="hljs-keyword"&gt;for&lt;/span&gt; item &lt;span class="hljs-keyword"&gt;in&lt;/span&gt; items_available.keys():
        &lt;span class="hljs-string"&gt;&amp;#34;${item}&amp;#34;&lt;/span&gt;: ${items_available[item]}${&lt;span class="hljs-string"&gt;&amp;#39;,&amp;#39;&lt;/span&gt; &lt;span class="hljs-keyword"&gt;if&lt;/span&gt; &lt;span class="hljs-keyword"&gt;not&lt;/span&gt; loop.last &lt;span class="hljs-keyword"&gt;else&lt;/span&gt; &lt;span class="hljs-string"&gt;&amp;#39;&amp;#39;&lt;/span&gt;} 
        %endfor
        }   
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The &lt;code&gt;%for&lt;/code&gt; and matching &lt;code&gt;%endfor&lt;/code&gt; mark the Python code off, which generates JSON via string-munging, complete with the check to make sure we&amp;#39;re not on the last iteration of the loop.&lt;/p&gt;
&lt;p&gt;Like so much bad code, this offers a degree of fractal wrongness. Instead of iterating over the keys and fetching the items inside the loop, you could iterate &lt;code&gt;for key,value in items_available.items()&lt;/code&gt;- and according to the Mako docs, that &lt;code&gt;for&lt;/code&gt; is just a regular Python &lt;code&gt;for&lt;/code&gt; loop. That we&amp;#39;re just outputting the contents of the dictionary is itself potentially a problem- sure, if we know the types of the dictionary, we&amp;#39;ll know that whatever it is can be output in the body of a JSON document, but do we really think this code is using type annotations? I don&amp;#39;t. And for a RESTful web service, I&amp;#39;m always going to feel weird about using a &lt;code&gt;success&lt;/code&gt; field when ideally the HTTP status code could convey most of that information (and yes, I know there are reasons to still put status in the body, I just hate it).&lt;/p&gt;
&lt;p&gt;Of course, the real issue is just: Python&amp;#39;s built in JSON serialization is actually pretty advanced. And performant! You don&amp;#39;t need any of this, you could just do something like:&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-python"&gt;&lt;span class="hljs-keyword"&gt;return&lt;/span&gt; json.dumps({&lt;span class="hljs-string"&gt;&amp;#34;success&amp;#34;&lt;/span&gt;: true, &lt;span class="hljs-string"&gt;&amp;#34;items&amp;#34;&lt;/span&gt;: items_available})
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;No templates. No formatting. No worries about how the data gets represented. Well, still worries, because JSON serialier will throw exceptions if it doesn&amp;#39;t know what to do with a type. But then at least you get that exception on the server side and aren&amp;#39;t sending the client a malformed document.&lt;/p&gt;
&lt;p&gt;In any case, this is a good demonstration that you can write bad PHP in any language.&lt;/p&gt;
&lt;!-- Easy Reader Version: I hate templating systems, if I'm being honest. --&gt;&lt;div&gt;
	&lt;img src="https://thedailywtf.com/images/inedo/proget-icon.png" style="display:block; float: left; margin: 0 10px 10px 0;"/&gt; [Advertisement] 
	Keep all your packages and Docker containers in one place, scan for vulnerabilities, and control who can access different feeds. ProGet installs in minutes and has a powerful free version with a lot of great features that you can upgrade when ready.&lt;a href="https://inedo.com/proget?utm_source=tdwtf&amp;amp;utm_medium=footer&amp;amp;utm_content=PlebsFooter"&gt;Learn more.&lt;/a&gt;
&lt;/div&gt;
&lt;div style="clear: left;"&gt; &lt;/div&gt;
</description><slash:comments>28</slash:comments><wfw:comment>https://thedailywtf.com/articles/comments/the-json-template</wfw:comment></item><item><dc:creator>Lyle Seaman</dc:creator><title>Error'd: April Showers</title><link>https://thedailywtf.com/articles/april-showers</link><category>Error'd</category><pubDate>Fri, 24 Apr 2026 06:30:00 GMT</pubDate><guid>https://thedailywtf.com/articles/april-showers</guid><description>&lt;p&gt;&amp;#34;RFC 1738 (and 3986) disagree&amp;#34; and so does
&lt;strong&gt;Daniel D.&lt;/strong&gt;
&amp;#34;Reddit API has some weird app creation going on with
lots of recently migrated and undocumented stuff. But having redirect
URL set to localhost (or 127.0.0.1) usually works. Well, if
you don&amp;#39;t disagree with Sir Tim Berners-Lee about what URL
is. Which Reddit does. hostnumber = digits &amp;#34;.&amp;#34; digits &amp;#34;.&amp;#34;
digits &amp;#34;.&amp;#34; digits&amp;#34;. I&amp;#39;d file this one with all the websites that try to perform validation on email addresses, and get it wrong.
&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;a href="#ad5bfafde9a74b7a8c38d429a364be48"&gt;&lt;img itemprop="image" border="0" alt="ad5bfafde9a74b7a8c38d429a364be48" src="https://d3hvi6t161kfmf.cloudfront.net/images/2026/04/23/ad5bfafde9a74b7a8c38d429a364be48.png"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;/blockquote&gt;


&lt;p&gt;&amp;#34;Why aren&amp;#39;t we getting any resumes?&amp;#34; wondered
&lt;strong&gt;Fred G.&lt;/strong&gt;
&amp;#34;This is a snippet from a job posting. I&amp;#39;m sure
it worked perfectly when HR tested it.&amp;#34;
&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;a href="#2c21d5766e724b9095103c6c537adfa3"&gt;&lt;img itemprop="image" border="0" alt="2c21d5766e724b9095103c6c537adfa3" src="https://d3hvi6t161kfmf.cloudfront.net/images/2026/04/23/2c21d5766e724b9095103c6c537adfa3.png"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;/blockquote&gt;


&lt;p&gt;&amp;#34;Service required...&amp;#34; was
&lt;strong&gt;Chris H.&lt;/strong&gt;&amp;#39;s title for this gem.
&amp;#34;My 2022 Chevrolet has been at the dealer for recall
service for two weeks now, &amp;#34;waiting for parts&amp;#34;. That doesn&amp;#39;t
stop GM from emailing every few days with a reminder
that the car needs the recall service, and inviting me
to schedule it at a dealer (that isn&amp;#39;t actually a
dealer) located a convenient 2500 mile drive from my home
(about 200 times the distance to the dealer where the
car currently sits), and providing a non-existent placeholder phone number
to contact them at to schedule the recall service.&amp;#34;
&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;a href="#78cac2590ecf4996a2f4ee79e0b38b49"&gt;&lt;img itemprop="image" border="0" alt="78cac2590ecf4996a2f4ee79e0b38b49" src="https://d3hvi6t161kfmf.cloudfront.net/images/2026/04/23/78cac2590ecf4996a2f4ee79e0b38b49.png"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;/blockquote&gt;


&lt;p&gt;&amp;#34;How to subtly tell your customers that you don&amp;#39;t wish to be contacted&amp;#34; explains
&lt;strong&gt;Yuri&lt;/strong&gt;.
&amp;#34;The bank&amp;#39;s staff must be wondering why no one wants
to talk to them...Is it their suit&amp;#39;s brand that is
throwing everyone off? Can they blame it on COVID?&amp;#34;
&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;a href="#81b84743c3a9405f8ed25c9c18b86029"&gt;&lt;img itemprop="image" border="0" alt="81b84743c3a9405f8ed25c9c18b86029" src="https://d3hvi6t161kfmf.cloudfront.net/images/2026/04/23/81b84743c3a9405f8ed25c9c18b86029.jpeg"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;/blockquote&gt;


&lt;p&gt;&amp;#34;Bad money formatting by tax software&amp;#34; 
&lt;strong&gt;Adam R.&lt;/strong&gt; complained.
&amp;#34;I&amp;#39;m ashamed to admit it, but yes, I did pay
Intuit money to file my taxes. This should really be
a free service provided by the government, but, y&amp;#39;know, *lobbying*.
You&amp;#39;d think that a business focused on tax preparation software
would know how to properly format currency values, but in
this case they failed to set the proper number of
decimal points.&amp;#34;
&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;a href="#a9085ecfb2d2403ebd3d856e0c2a1179"&gt;&lt;img itemprop="image" border="0" alt="a9085ecfb2d2403ebd3d856e0c2a1179" src="https://d3hvi6t161kfmf.cloudfront.net/images/2026/04/23/a9085ecfb2d2403ebd3d856e0c2a1179.png"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;/blockquote&gt;

&lt;div&gt;
	&lt;img src="https://thedailywtf.com/images/inedo/buildmaster-icon.png" style="display:block; float: left; margin: 0 10px 10px 0;"/&gt; [Advertisement] 
	&lt;a href="https://inedo.com/BuildMaster?utm_source=tdwtf&amp;amp;utm_medium=footerad&amp;amp;utm_term=2018&amp;amp;utm_content=Self_Service&amp;amp;utm_campaign=Buildmaster_Footer"&gt;BuildMaster&lt;/a&gt; allows you to create a self-service release management platform that allows different teams to manage their applications. &lt;a href="https://inedo.com/BuildMaster/download?utm_source=tdwtf&amp;amp;utm_medium=footerad&amp;amp;utm_term=2018&amp;amp;utm_content=Self_Service&amp;amp;utm_campaign=Buildmaster_Footer"&gt;Explore how!&lt;/a&gt; 
&lt;/div&gt;
&lt;div style="clear: left;"&gt; &lt;/div&gt;
</description><slash:comments>15</slash:comments><wfw:comment>https://thedailywtf.com/articles/comments/april-showers</wfw:comment></item><item><dc:creator>Remy Porter</dc:creator><title>CodeSOD: Tune Out the Static</title><link>https://thedailywtf.com/articles/tune-out-the-static</link><category>CodeSOD</category><pubDate>Thu, 23 Apr 2026 06:30:00 GMT</pubDate><guid>https://thedailywtf.com/articles/tune-out-the-static</guid><description>&lt;p&gt;&lt;strong&gt;Henrik H&lt;/strong&gt; (&lt;a href="https://thedailywtf.com/articles/years-go-by"&gt;previously&lt;/a&gt;) sends us a simple representative C# line:&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-csharp"&gt;&lt;span class="hljs-function"&gt;&lt;span class="hljs-keyword"&gt;static&lt;/span&gt; &lt;span class="hljs-keyword"&gt;void&lt;/span&gt; &lt;span class="hljs-title"&gt;GenerateCommercilaInvoice&lt;/span&gt;()
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;This is a static method which takes no parameters and returns nothing. Henrik didn&amp;#39;t share the implementation, but this static function likely does something that involves side effects, maybe manipulating the database (to generate that invoice?). Or, possibly worse, it could be doing something with some global or static state. It&amp;#39;s all side effects and no meaningful controls, so enjoy debugging &lt;em&gt;that&lt;/em&gt; when things go wrong. Heck, good luck &lt;em&gt;testing&lt;/em&gt; it. Our best case possibility is that it&amp;#39;s just a wrapper around a call to a stored procedure.&lt;/p&gt;
&lt;p&gt;This method signature is basically a commercila for refactoring.&lt;/p&gt;
&lt;!-- Easy Reader Version: For some reason, the spellchecker extension I use in VS Code has stopped working, and that's annoying me. --&gt;&lt;div&gt;
	&lt;img src="https://thedailywtf.com/images/inedo/proget-icon.png" style="display:block; float: left; margin: 0 10px 10px 0;"/&gt; [Advertisement] 
	ProGet’s got you covered with security and access controls on your NuGet feeds. &lt;a href="https://inedo.com/proget/private-nuget-server?utm_source=tdwtf&amp;amp;utm_medium=footer&amp;amp;utm_content=GotYouCoveredFooter&amp;amp;utm_campaign=Cyclops2020"&gt;Learn more.&lt;/a&gt;
&lt;/div&gt;
&lt;div style="clear: left;"&gt; &lt;/div&gt;
</description><slash:comments>13</slash:comments><wfw:comment>https://thedailywtf.com/articles/comments/tune-out-the-static</wfw:comment></item><item><dc:creator>Remy Porter</dc:creator><title>Representative Line: Comment Overflow</title><link>https://thedailywtf.com/articles/comment-overflow</link><category>Representative Line</category><pubDate>Wed, 22 Apr 2026 06:30:00 GMT</pubDate><guid>https://thedailywtf.com/articles/comment-overflow</guid><description>&lt;p&gt;Today, we look at a representative comment, sent to us by &lt;strong&gt;Nona&lt;/strong&gt;. This particular comment was in a pile of code delivered by an offshore team.&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-javascript"&gt;&lt;span class="hljs-comment"&gt;// https://stackoverflow.com/questions/46744740/lodash-mongoose-object-id-difference/46745169&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&amp;#34;Wait,&amp;#34; you say, &amp;#34;what&amp;#39;s the WTF about a comment pointing to a Stack Overflow page. I do that all the time?&amp;#34;&lt;/p&gt;
&lt;p&gt;In this case, it&amp;#39;s because this particular comment wasn&amp;#39;t given any further explanation. It also wasn&amp;#39;t in a block of code that was doing anything with either lodash, Mongoose, or set differences. It was, however, repeated multiple times throughout the codebase, because the entire codebase was a pile of copy-pasta glued together with the bare minimum code to make it work.&lt;/p&gt;
&lt;p&gt;In at least one place, the comment was probably correct and helpful. But it got swept up as part of a broader copy/paste exercise, and now is scattered through the code without any true purpose.&lt;/p&gt;
&lt;!-- Easy Reader Version: If you need AI to generate millions of lines of slop, you're just not trying hard enough. --&gt;&lt;div&gt;
	&lt;img src="https://thedailywtf.com/images/inedo/proget-icon.png" style="display:block; float: left; margin: 0 10px 10px 0;"/&gt; [Advertisement] 
	Keep the plebs out of prod. Restrict NuGet feed privileges with ProGet. &lt;a href="https://inedo.com/proget/private-nuget-server?utm_source=tdwtf&amp;amp;utm_medium=footer&amp;amp;utm_content=PlebsFooter&amp;amp;utm_campaign=Cyclops2020"&gt;Learn more.&lt;/a&gt;
&lt;/div&gt;
&lt;div style="clear: left;"&gt; &lt;/div&gt;
</description><slash:comments>12</slash:comments><wfw:comment>https://thedailywtf.com/articles/comments/comment-overflow</wfw:comment></item><item><dc:creator>Remy Porter</dc:creator><title>Turning Thirty</title><link>https://thedailywtf.com/articles/turning-thirty</link><category>Feature Articles</category><pubDate>Tue, 21 Apr 2026 06:30:00 GMT</pubDate><guid>https://thedailywtf.com/articles/turning-thirty</guid><description>&lt;p&gt;&lt;strong&gt;Eric O&lt;/strong&gt; worked for a medical device company. The medical device industry moves slowly, relative to other technical industries. Medical science and safety have their own cadence, and at a certain point, iterating faster doesn&amp;#39;t matter much.&lt;/p&gt;
&lt;p&gt;Eric was working on a new feature on a system that had been in use for thirteen years. This new feature interacted with a database which stored information about racks of test tubes, and Eric&amp;#39;s tests meant creating several entries for racks of test tubes. And that&amp;#39;s when Eric discovered that the database only allowed thirty racks. Add any more, it would just roll right back over to one.&lt;/p&gt;
&lt;p&gt;This was odd. The database was small- less than 40MB, even in production- and there were automatic tasks to purge old data for compliance purposes. Why a hard limit of thirty?&lt;/p&gt;
&lt;p&gt;Eric had only been at the company for a year, so he asked one of the more senior team members, Lester. &amp;#34;Oh yeah, that was before my time. You should probably ask Carl.&amp;#34;&lt;/p&gt;
&lt;p&gt;Later that day, Eric happened to bump into Carl around the coffee maker, and asked the question. &amp;#34;Oh, yeah, I do vaguely remember something about that. It was in the requirements for the product. I thought it was weird, but didn&amp;#39;t think too much about it. You should probably ask Elise, she&amp;#39;s been here like twenty years.&amp;#34;&lt;/p&gt;
&lt;p&gt;Well, now it was getting curious. Eric went over to the &amp;#34;old building&amp;#34;, as it was named, the original office for the company on the other side of the parking lot. Most of the offices had moved to the new building a decade earlier, and it mostly served as fabrication and storage, but a few offices remained.&lt;/p&gt;
&lt;p&gt;Elise was on the third floor, down a poorly lit hallway, sitting in an office with water-stained acoustical tile in its ceiling. &amp;#34;Oh, yeah, I put that into the requirements document. It&amp;#39;s funny, I thought it was weird too, but the system you&amp;#39;re working on was a replacement for an older system. Our requirements were derived from those. Let me think… Irving worked on that, but he&amp;#39;s dead, god rest him. Penny is retired. Oh, you know, Humbert is still around. He didn&amp;#39;t work on that, but he worked on some of the systems that came before that. He&amp;#39;s upstairs and on the other side of the building.&amp;#34;&lt;/p&gt;
&lt;p&gt;Eric went upstairs and to the other side of the building. The fourth floor had been last remodeled circa 1985, and the ugly industrial paint on the wall was made even uglier by the fact that someone had replaced most of the flourescent tubes with LEDs. &lt;em&gt;Most&lt;/em&gt;. The mismatched color temperature started Eric down the path of a headache.&lt;/p&gt;
&lt;p&gt;Humbert was in an office similar to Elise&amp;#39;s. On his desk was a plaque commemerating 40 years of service with the company. Eric asked about the limitation, and Humbert laughed.&lt;/p&gt;
&lt;p&gt;&amp;#34;You&amp;#39;re working on the latest version of a product that initially started on an old PDP-11 running &lt;a href="https://thedailywtf.com/articles/a_case_of_the_mumps"&gt;MUMPS&lt;/a&gt;. I mean, the first versions, anyway. We ran to desktop computers as fast as we could. I wrote a version for DOS in… oh… &amp;#39;86? I knew none of the facilities we worked with had more than ten or fifteen racks of tubes, and I needed somehow to limit the size of the database so it all fit on a single 5 1/4&amp;#34; floppy disk. I picked thirty, because it seemed like a good round number. Honestly, I&amp;#39;m shocked that the limit still exists.&amp;#34;&lt;/p&gt;
&lt;p&gt;So was Eric. There had been several ground-up-rewrites since 1986, before the one Eric maintained had been released thirteen years ago. Each one of them had chosen to maintain the same limitation, without ever considering why it existed. The rule had simply been copied, mindlessly, for 40 years.&lt;/p&gt;
&lt;p&gt;&amp;#34;I&amp;#39;m kind of impressed,&amp;#34; Eric said to Humbert, &amp;#34;in a horrified way.&amp;#34;&lt;/p&gt;
&lt;p&gt;&amp;#34;Me too, kid, me too.&amp;#34;&lt;/p&gt;
&lt;!-- Easy Reader Version: I've worked on systems like this, and I expect that someone at some point did a weird workaround to make it possible to have "subracks", where you could divide each real rack into thirty subracks, thus allowing you to have more than the abritrary limit usually allowed. --&gt;&lt;div&gt;
	&lt;img src="https://thedailywtf.com/images/inedo/proget-icon.png" style="display:block; float: left; margin: 0 10px 10px 0;"/&gt; [Advertisement] 
	Keep all your packages and Docker containers in one place, scan for vulnerabilities, and control who can access different feeds. ProGet installs in minutes and has a powerful free version with a lot of great features that you can upgrade when ready.&lt;a href="https://inedo.com/proget?utm_source=tdwtf&amp;amp;utm_medium=footer&amp;amp;utm_content=PlebsFooter"&gt;Learn more.&lt;/a&gt;
&lt;/div&gt;
&lt;div style="clear: left;"&gt; &lt;/div&gt;
</description><slash:comments>36</slash:comments><wfw:comment>https://thedailywtf.com/articles/comments/turning-thirty</wfw:comment></item><item><dc:creator>Remy Porter</dc:creator><title>CodeSOD: Good Etiquette</title><link>https://thedailywtf.com/articles/good-etiquette</link><category>CodeSOD</category><pubDate>Mon, 20 Apr 2026 06:30:00 GMT</pubDate><guid>https://thedailywtf.com/articles/good-etiquette</guid><description>&lt;p&gt;&amp;#34;Here, you&amp;#39;re a programmer, take this over. It&amp;#39;s business critical.&amp;#34;&lt;/p&gt;
&lt;p&gt;That&amp;#39;s what &lt;strong&gt;Felicity&lt;/strong&gt;&amp;#39;s boss told her when he pointed her to a network drive containing an Excel spreadsheet. The Excel spreadsheet contained a pile of macros. The person who wrote it had left, and nobody knew how to make it work, but the macros in question were absolutely business vital.&lt;/p&gt;
&lt;p&gt;Also, it&amp;#39;s in French.&lt;/p&gt;
&lt;p&gt;We&amp;#39;ll take this one in chunks. The indentation is as in the original.&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-vbscript"&gt;&lt;span class="hljs-keyword"&gt;Public&lt;/span&gt; &lt;span class="hljs-keyword"&gt;Sub&lt;/span&gt; ExporToutVersBaseDonnées(ClasseurEnCours As Workbook)
&lt;span class="hljs-keyword"&gt;Call&lt;/span&gt; AffectionVariables(ToutesLesCellulesNommées)
&lt;span class="hljs-keyword"&gt;Call&lt;/span&gt; AffectationBaseDonnées(BaseDonnées)
BaseDonnées.Activate
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The procedures &lt;code&gt;AffectionVariables&lt;/code&gt; and &lt;code&gt;AffectationBaseDonnées&lt;/code&gt; populate a pile of global variables. &amp;#34;base de données&amp;#34; is French for database, but don&amp;#39;t let the name fool you- anything referencing &amp;#34;base de données&amp;#34; is referencing another Excel file located on a shared server. There are, in total, four Excel files that must live on a shared server, and two more which must be in a hard-coded path on the user&amp;#39;s computer.&lt;/p&gt;
&lt;p&gt;Oh, and the shared server is referenced not by a hostname, but by IP address- which is why the macros were breaking on everyone&amp;#39;s computer; the IP address changed.&lt;/p&gt;
&lt;p&gt;Let&amp;#39;s continue.&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-vbscript"&gt;&lt;span class="hljs-comment"&gt;&amp;#39;Vérifier si la ligne existe déjà.&lt;/span&gt;
        &lt;span class="hljs-keyword"&gt;If&lt;/span&gt; ClasseurEnCours.Sheets(&lt;span class="hljs-string"&gt;&amp;#34;DATA&amp;#34;&lt;/span&gt;).Range(&lt;span class="hljs-string"&gt;&amp;#34;Num_Fichier&amp;#34;&lt;/span&gt;) = &lt;span class="hljs-number"&gt;0&lt;/span&gt; &lt;span class="hljs-keyword"&gt;Then&lt;/span&gt;
        Num_Fichier = BaseDonnées.Sheets(&lt;span class="hljs-number"&gt;1&lt;/span&gt;).Range(&lt;span class="hljs-string"&gt;&amp;#34;Dernier_Fichier&amp;#34;&lt;/span&gt;).Value + &lt;span class="hljs-number"&gt;1&lt;/span&gt;
Insérer_Ligne: &lt;span class="hljs-comment"&gt;&amp;#39;(étiquette Goto) insérer une ligne&lt;/span&gt;
    Application.&lt;span class="hljs-keyword"&gt;GoTo&lt;/span&gt; Reference:=&lt;span class="hljs-string"&gt;&amp;#34;Dernière_Ligne&amp;#34;&lt;/span&gt;
            Selection.EntireRow.Insert
&lt;span class="hljs-comment"&gt;&amp;#39;Copie les cellules (colonne A à colonne FI) de la ligne au-dessus de la ligne insérée.&lt;/span&gt;
            &lt;span class="hljs-keyword"&gt;With&lt;/span&gt; ActiveCell
                    .Offset(&lt;span class="hljs-number"&gt;-1&lt;/span&gt;, &lt;span class="hljs-number"&gt;0&lt;/span&gt;).Range(&lt;span class="hljs-string"&gt;&amp;#34;A1:FM1&amp;#34;&lt;/span&gt;).Copy
&lt;span class="hljs-comment"&gt;&amp;#39;Colle le format de la cellule précédemment copiée à la cellule active puis libère les données du presse papier&lt;/span&gt;
                    .PasteSpecial
                    .Range(&lt;span class="hljs-string"&gt;&amp;#34;A1:FM1&amp;#34;&lt;/span&gt;).Value = &lt;span class="hljs-string"&gt;&amp;#34;&amp;#34;&lt;/span&gt;
&lt;span class="hljs-comment"&gt;&amp;#39;Se repositionne au début de la ligne insérée.&lt;/span&gt;
                    .Range(&lt;span class="hljs-string"&gt;&amp;#34;A1&amp;#34;&lt;/span&gt;).&lt;span class="hljs-keyword"&gt;Select&lt;/span&gt;
            &lt;span class="hljs-keyword"&gt;End&lt;/span&gt; &lt;span class="hljs-keyword"&gt;With&lt;/span&gt;
            Application.CutCopyMode = &lt;span class="hljs-literal"&gt;False&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Uh oh, &lt;code&gt;Insérer_Ligne&lt;/code&gt; is a label for a &lt;code&gt;Goto&lt;/code&gt; target. Not to be confused by the &lt;code&gt;Application.GoTo&lt;/code&gt; call on the next line- that just selects a range in the spreadsheet.&lt;/p&gt;
&lt;p&gt;After that little landmine, we copy/paste some data around in the sheet.&lt;/p&gt;
&lt;p&gt;That&amp;#39;s the &lt;code&gt;If&lt;/code&gt; side of the conditional, let&amp;#39;s look at the &lt;code&gt;else&lt;/code&gt; clause:&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-vbscript"&gt;        &lt;span class="hljs-keyword"&gt;Else&lt;/span&gt;
Cherche_Numéro_Fichier: &lt;span class="hljs-comment"&gt;&amp;#39; Chercher la ligne ou le numéro de fichier est égale à NumFichier.&lt;/span&gt;
                        &lt;span class="hljs-keyword"&gt;While&lt;/span&gt; ActiveCell.Value &amp;lt;&amp;gt; Num_Fichier
                &lt;span class="hljs-keyword"&gt;If&lt;/span&gt; ActiveCell.Row = Range(&lt;span class="hljs-string"&gt;&amp;#34;Etiquettes&amp;#34;&lt;/span&gt;).Row &lt;span class="hljs-keyword"&gt;Then&lt;/span&gt;
                    &lt;span class="hljs-keyword"&gt;GoTo&lt;/span&gt; Insérer_Ligne
                &lt;span class="hljs-keyword"&gt;End&lt;/span&gt; &lt;span class="hljs-keyword"&gt;If&lt;/span&gt;
                ActiveCell.Offset(&lt;span class="hljs-number"&gt;-1&lt;/span&gt;, &lt;span class="hljs-number"&gt;0&lt;/span&gt;).Range(&lt;span class="hljs-string"&gt;&amp;#34;a1:a1&amp;#34;&lt;/span&gt;).&lt;span class="hljs-keyword"&gt;Select&lt;/span&gt;
            &lt;span class="hljs-keyword"&gt;Wend&lt;/span&gt;
            &lt;span class="hljs-comment"&gt;&amp;#39;Vérifier le numéro d&amp;#39;indice de la ligne active.&lt;/span&gt;
                &lt;span class="hljs-keyword"&gt;If&lt;/span&gt; Cells(ActiveCell.Row, &lt;span class="hljs-number"&gt;165&lt;/span&gt;).Value &amp;lt;&amp;gt; ClasseurEnCours.Sheets(&lt;span class="hljs-string"&gt;&amp;#34;DATA&amp;#34;&lt;/span&gt;).Range(&lt;span class="hljs-string"&gt;&amp;#34;Dernier_Indice&amp;#34;&lt;/span&gt;) &lt;span class="hljs-keyword"&gt;Then&lt;/span&gt;
                    ActiveCell.Offset(&lt;span class="hljs-number"&gt;-1&lt;/span&gt;, &lt;span class="hljs-number"&gt;0&lt;/span&gt;).Range(&lt;span class="hljs-string"&gt;&amp;#34;A1:A1&amp;#34;&lt;/span&gt;).&lt;span class="hljs-keyword"&gt;Select&lt;/span&gt;
                    &lt;span class="hljs-keyword"&gt;GoTo&lt;/span&gt; Cherche_Numéro_Fichier
                &lt;span class="hljs-keyword"&gt;End&lt;/span&gt; &lt;span class="hljs-keyword"&gt;If&lt;/span&gt;
            ActiveCell.Offset(&lt;span class="hljs-number"&gt;0&lt;/span&gt;, &lt;span class="hljs-number"&gt;0&lt;/span&gt;).Range(&lt;span class="hljs-string"&gt;&amp;#34;A1:FM1&amp;#34;&lt;/span&gt;).Value = &lt;span class="hljs-string"&gt;&amp;#34;&amp;#34;&lt;/span&gt;
        &lt;span class="hljs-keyword"&gt;End&lt;/span&gt; &lt;span class="hljs-keyword"&gt;If&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;We start with another label, and… then we have a &lt;code&gt;Goto&lt;/code&gt;. A &lt;code&gt;Goto&lt;/code&gt; which jumps us back into the &lt;code&gt;If&lt;/code&gt; side of the conditional. A &lt;code&gt;Goto&lt;/code&gt; inside of a while loop, a while loop that&amp;#39;s marching around the spreadsheet to search for certain values in the cell.&lt;/p&gt;
&lt;p&gt;After the loop, we have &lt;em&gt;another&lt;/em&gt; &lt;code&gt;Goto&lt;/code&gt; which will possibly jump us up to the start of the &lt;code&gt;else&lt;/code&gt; block.&lt;/p&gt;
&lt;p&gt;The procedure ends with some cleanup:&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-vbscript"&gt;&lt;span class="hljs-comment"&gt;&amp;#39;----- &lt;/span&gt;
&lt;span class="hljs-comment"&gt;&amp;#39; Do some stuff on the active cell and the following cells on the column&lt;/span&gt;
.-----
BaseDonnées.Close &lt;span class="hljs-literal"&gt;True&lt;/span&gt;
&lt;span class="hljs-keyword"&gt;Set&lt;/span&gt; BaseDonnées = &lt;span class="hljs-literal"&gt;Nothing&lt;/span&gt;
&lt;span class="hljs-keyword"&gt;End&lt;/span&gt; &lt;span class="hljs-keyword"&gt;Sub&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;I do not know what this function does, and the fact that the code is largely in a language I don&amp;#39;t speak isn&amp;#39;t the obstacle. I have no idea what the loops and the gotos are trying to do. I&amp;#39;m not even a &amp;#34;never use &lt;code&gt;Goto&lt;/code&gt; ever ever ever&amp;#34; person; in a language like VBA, it&amp;#39;s sometimes the best way to handle errors. But this bizarre time-traveling flow control boggles me.&lt;/p&gt;
&lt;p&gt;&amp;#34;Etiquettes&amp;#34; is French for &amp;#34;labels&amp;#34;, and it may be bad etiquette but I&amp;#39;ve got some four letter labels for this code.&lt;/p&gt;
&lt;!-- Easy Reader Version: GOTO considered harmful? Yeah, to my *sanity* --&gt;&lt;div&gt;
	&lt;img src="https://thedailywtf.com/images/inedo/proget-icon.png" style="display:block; float: left; margin: 0 10px 10px 0;"/&gt; [Advertisement] 
	ProGet’s got you covered with security and access controls on your NuGet feeds. &lt;a href="https://inedo.com/proget/private-nuget-server?utm_source=tdwtf&amp;amp;utm_medium=footer&amp;amp;utm_content=GotYouCoveredFooter&amp;amp;utm_campaign=Cyclops2020"&gt;Learn more.&lt;/a&gt;
&lt;/div&gt;
&lt;div style="clear: left;"&gt; &lt;/div&gt;
</description><slash:comments>16</slash:comments><wfw:comment>https://thedailywtf.com/articles/comments/good-etiquette</wfw:comment></item><item><dc:creator>Lyle Seaman</dc:creator><title>Error'd: Having a Beastly Time</title><link>https://thedailywtf.com/articles/having-a-beastly-time</link><category>Error'd</category><pubDate>Fri, 17 Apr 2026 06:30:00 GMT</pubDate><guid>https://thedailywtf.com/articles/having-a-beastly-time</guid><description>&lt;p&gt;It&amp;#39;s time again for a reader special, and once again it&amp;#39;s all &lt;strong&gt;The Beast In Black&lt;/strong&gt; (there must be a story to that nick, no?).&lt;/p&gt;

&lt;p&gt;&amp;#34;MySQL is not better than your SQL,&amp;#34; he pontificated, 
&amp;#34;especially when
it comes to the Workbench Migration Wizard&amp;#34;
&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;a href="#7369002fc20e41b89b64ed7f32ef3641"&gt;&lt;img itemprop="image" border="0" alt="7369002fc20e41b89b64ed7f32ef3641" src="https://d3hvi6t161kfmf.cloudfront.net/images/2026/04/05/7369002fc20e41b89b64ed7f32ef3641.png"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;/blockquote&gt;

&lt;p&gt;&amp;#34;Sadly,&amp;#34; says he, 
&amp;#34;Not even gmail/chromium either.&amp;#34;
&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;a href="#149c9109443f4521b1a38b91bd0bcc22"&gt;&lt;img itemprop="image" border="0" alt="149c9109443f4521b1a38b91bd0bcc22" src="https://d3hvi6t161kfmf.cloudfront.net/images/2026/04/05/149c9109443f4521b1a38b91bd0bcc22.png"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;/blockquote&gt;

&lt;p&gt;&amp;#34;Updated software is available, but there are no updates!&amp;#34; he puzzled.
&amp;#34;Clicking Install Now just throws
that dialog right back in my face. I&amp;#39;m re-cursing.&amp;#34; Zero, one, does it really make a difference?
&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;a href="#e9ea57c886984dc8a106df503a2fd923"&gt;&lt;img itemprop="image" border="0" alt="e9ea57c886984dc8a106df503a2fd923" src="https://d3hvi6t161kfmf.cloudfront.net/images/2026/04/05/e9ea57c886984dc8a106df503a2fd923.png"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;/blockquote&gt;

&lt;p&gt;&amp;#34;Questions&amp;#34;
&lt;strong&gt;The Beast in Black&lt;/strong&gt;
&amp;#34;I do, in fact, have a question...&amp;#34;
&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;a href="#f5c83f7bc02644a895f1f9aa5ec368a1"&gt;&lt;img itemprop="image" border="0" alt="f5c83f7bc02644a895f1f9aa5ec368a1" src="https://d3hvi6t161kfmf.cloudfront.net/images/2026/04/05/f5c83f7bc02644a895f1f9aa5ec368a1.png"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;/blockquote&gt;

&lt;p&gt;One of the foundational guides to my [lyle, not bib] engineering career
was John Bentley&amp;#39;s &lt;em&gt;Programming Pearls&lt;/em&gt;. These are not those.
&lt;br/&gt;
&amp;#34;Veni, vidi: vc. No pearls of wisdom here, just litter.&amp;#34; says
&lt;strong&gt;The Beast&lt;/strong&gt;.
&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;a href="#4e13a188deb94473abcc6148d106458c"&gt;&lt;img itemprop="image" border="0" alt="4e13a188deb94473abcc6148d106458c" src="https://d3hvi6t161kfmf.cloudfront.net/images/2026/04/05/4e13a188deb94473abcc6148d106458c.png"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;/blockquote&gt;


&lt;div&gt;
	[Advertisement] &lt;b&gt;Plan Your .NET 9 Migration with Confidence&lt;/b&gt;&lt;br/&gt;Your journey to .NET 9 is more than just one decision.Avoid migration migraines with the advice in this free guide. &lt;b&gt;&lt;a href="https://inedo.com/support/whitepapers/dotnet-guide?utm_campaign=dotnet&amp;amp;utm_source=tdwtf-footer"&gt;Download Free Guide Now!&lt;/a&gt;&lt;/b&gt;
&lt;/div&gt;
&lt;div style="clear: left;"&gt; &lt;/div&gt;</description><slash:comments>12</slash:comments><wfw:comment>https://thedailywtf.com/articles/comments/having-a-beastly-time</wfw:comment></item><item><dc:creator>Remy Porter</dc:creator><title>CodeSOD: We'll Hire Better Contractors Next Time, We Promise</title><link>https://thedailywtf.com/articles/we-ll-hire-better-contractors-next-time-we-promise</link><category>CodeSOD</category><pubDate>Thu, 16 Apr 2026 06:30:00 GMT</pubDate><guid>https://thedailywtf.com/articles/we-ll-hire-better-contractors-next-time-we-promise</guid><description>&lt;p&gt;&lt;strong&gt;Nona&lt;/strong&gt; writes: &amp;#34;this is the beginning of a 2100 line function.&amp;#34;&lt;/p&gt;
&lt;p&gt;That&amp;#39;s bad. Nona didn&amp;#39;t send us the entire JavaScript function, but sent us just the three early lines, which definitely raise concerns:&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-javascript"&gt;&lt;span class="hljs-keyword"&gt;if&lt;/span&gt; (res.&lt;span class="hljs-property"&gt;length&lt;/span&gt; &amp;gt; &lt;span class="hljs-number"&gt;0&lt;/span&gt;) {
  &lt;span class="hljs-keyword"&gt;await&lt;/span&gt; (&lt;span class="hljs-keyword"&gt;function&lt;/span&gt; (&lt;span class="hljs-params"&gt;&lt;/span&gt;) {
    &lt;span class="hljs-keyword"&gt;return&lt;/span&gt; &lt;span class="hljs-keyword"&gt;new&lt;/span&gt; &lt;span class="hljs-title class_"&gt;Promise&lt;/span&gt;(&lt;span class="hljs-function"&gt;(&lt;span class="hljs-params"&gt;resolve, reject&lt;/span&gt;) =&amp;gt;&lt;/span&gt; {
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;We await a synchronous function which retuns a promise, passing a function to the promise. As a general rule, you don&amp;#39;t construct promises directly, you let asynchronous code generate them and pass them around (or await them). It&amp;#39;s not a thing you &lt;em&gt;never&lt;/em&gt; do, but it&amp;#39;s certainly suspicious. It gets more problematic when Nona adds:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;This function happens to contain multiple code repetition snippets, including these three lines.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;That&amp;#39;s right, this little block appears multiple times in the function, &lt;em&gt;inside&lt;/em&gt; of anonymous function getting passed to the &lt;code&gt;Promise&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;No, the code does not work in its current state. It&amp;#39;s unclear what the 2100 line function was supposed to do. And yes, this was written by lowest-bidder third-party contractors.&lt;/p&gt;
&lt;p&gt;Nona adds:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;I am numb at this point and know I gotta fix it or we lose contracts&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Management made the choice to &amp;#34;save money&amp;#34; by hiring third parties, and now Nona&amp;#39;s team gets saddled with all the crunch to fix the problems created by the &amp;#34;savings&amp;#34;.&lt;/p&gt;
&lt;!-- Easy Reader Version: "lowest bidder" plans to make as much, if not more profit, than the highest bidder- they just plan to spend way less doing it. --&gt;&lt;div&gt;
	[Advertisement] &lt;b&gt;Plan Your .NET 9 Migration with Confidence&lt;/b&gt;&lt;br/&gt;Your journey to .NET 9 is more than just one decision.Avoid migration migraines with the advice in this free guide. &lt;b&gt;&lt;a href="https://inedo.com/support/whitepapers/dotnet-guide?utm_campaign=dotnet&amp;amp;utm_source=tdwtf-footer"&gt;Download Free Guide Now!&lt;/a&gt;&lt;/b&gt;
&lt;/div&gt;
&lt;div style="clear: left;"&gt; &lt;/div&gt;</description><slash:comments>14</slash:comments><wfw:comment>https://thedailywtf.com/articles/comments/we-ll-hire-better-contractors-next-time-we-promise</wfw:comment></item></channel></rss>