WTF Bites



  • @Bulb said in WTF Bites:

    using Cygwin means a full unixy environment is desired.

    Indeed. I've been using Cygwin for decades for grep, find, tar, bash, diff, bzip2, gcc, [g]vim, rsync, which, whois and all the other unixy utilities. Python is merely one of the tools that is installed in that environment. Also perl and tcl.

    Also, a 2014 version of ActiveState Python 3.4 (in C:\Python34, of course, because why write an installer that installs to the place where programs are supposed to install themselves when you can be a ❄?) that I forgot I even had installed.

    @Bulb said in WTF Bites:

    Or just switch to WSL2

    Maybe, when I have Win10.



  • @HardwareGeek said in WTF Bites:

    Indeed. I've been using Cygwin for decades for grep, find, tar, bash, diff, bzip2, gcc, [g]vim, rsync, which, whois and all the other unixy utilities. Python is merely one of the tools that is installed in that environment. Also perl and tcl.

    Yeah, I did as well, but then when git-for-windows came out based on the msys2 I switched to either just using the “git bash” if what is included in it is enough (it does have python, perl and tcl, but the package manager is not included, so you can't easily install anything extra) or installing the full msys2, exactly because the package manager is actually sensible.

    And because it can do the path wriggling when running normal Windows programs expecting backslashes.

    @HardwareGeek said in WTF Bites:

    in C:\Python34, of course, because why write an installer that installs to the place where programs are supposed to install themselves when you can be a ❄ ?

    It's surprising how few people realize paths in Windows can always be expressed without spaces.

    Also python isn't the program I'd expect to have problems with spaces, but probably some library they wanted to include did.



  • @Bulb said in WTF Bites:

    It's surprising how few people realize paths in Windows can always be expressed without spaces.

    I don't think that true in general. Even if they often do, short names are not guaranteed to exist (it's possible to disable them).

    Of course, that's not an excuse, since spaces in Windows paths have been a thing for a quarter of a century now.



  • @Zerosquare said in WTF Bites:

    Even if they often do, short names are not guaranteed to exist (it's possible to disable them).

    Did anybody ever care enough to actually disable them?

    And then, the installer can check they exist and issue a warning that they are recommended and some things may break without them.



  • @Bulb said in WTF Bites:

    Also python isn't the program I'd expect to have problems with spaces, but probably some library they wanted to include did.

    I think the problem probably wasn't Python. ActiveState Perl and I think tcl (although I haven't used either in many years, so I'm not entirely sure about tcl) also installed themselves under C:. The problem is much more likely lazy ActiveState devs who haven't updated their installer since Win3.1.



  • @Zerosquare said in WTF Bites:

    Of course, that's not an excuse, since spaces in Windows paths have been a thing for a quarter of a century now.

    They've also been allowed on most unixy systems for even longer, though they were not common there.


  • Discourse touched me in a no-no place

    @HardwareGeek said in WTF Bites:

    I think the problem probably wasn't Python. ActiveState Perl and I think tcl (although I haven't used either in many years, so I'm not entirely sure about tcl) also installed themselves under C:. The problem is much more likely lazy ActiveState devs who haven't updated their installer since Win3.1.

    Tcl's very happy about spaces in paths (except when building it from C sources) unless people do very ugly things in their code. I don't recall the Python integration making that mistake.



  • @HardwareGeek Turns out that there is an option to get it to use an "sslproxy".

    It's just that there's a hidden configuration file with default values for a lot more options than their user-editable config file presents.

    I'm not sure how much sense having two config files actually makes. In my naive assumption, there should be one with all the options. But what do I know.


  • BINNED

    @Bulb said in WTF Bites:

    And then, the installer can check they exist and issue a warning that they are recommended and some things may break without them.

    Or they could actually do the right thing once in their lifetime, fix the damn software and remove it from Big list of software that cannot handle spaces or accents in paths.

    Pipe dream, I know.



  • How long until some idiot with more 💸 than 🧠 takes them to have them laundered? "Sorry for the extra charge, but it took us a lot of work to get all those stains out. Maybe next time you should wear Levis for mowing your lawn."



  • @HardwareGeek said in WTF Bites:

    ActiveState

    I used to use that. I switched to python.org's version (plus https://github.com/mhammond/pywin32)



  • @Rhywden There's sometimes need to have different defaults on different kinds of installation targets. So 2 files could be defended, at least on academic grounds.

    Also, if this is still about the same problem-child with the nginx server, you could configure it to serve certain files and paths via plain http. If your server were to have 10k+ simultaneous users, it may even make a difference in workload.


  • BINNED

    qtc_open.png

    Welcome to the 90s! :airquotes: HUGE :trump: :airquotes:

    sys_load.png

    Go ahead, I think it'll be fine.



  • @topspin Don't you see that your machine's memory is larger than can be expressed with a signed or unsigned 32bit integer number?
    There's the problem: after throwing away the most important bits, the remaining memory might be even negative now...



  • @topspin Fair warning:
    Qt Creator's text editor chokes (or used to choke; haven't tried in a while) on long lines. Like, several thousand characters long lines. UI slowed to a slide-show until you close the file.

    How I know? There was a time when I had to convert binary data to C arrays in a way that worked with IAR EWARM, and then we made some tests with a Qt-written GUI.
    I had to tweak a script to add some line breaks to the C arrays, to finally get rid of the issue.


  • BINNED

    @acrow said in WTF Bites:

    @topspin Fair warning:
    Qt Creator's text editor chokes (or used to choke; haven't tried in a while) on long lines. Like, several thousand characters long lines. UI slowed to a slide-show until you close the file.

    How I know? There was a time when I had to convert binary data to C arrays in a way that worked with IAR EWARM, and then we made some tests with a Qt-written GUI.
    I had to tweak a script to add some line breaks to the C arrays, to finally get rid of the issue.

    Yeah, I've experienced things like that before on a wide variety of text editors on both Windows and Linux. That's about line length though, and you can get absurdly long lines which would make it choke even with a 100KB file, which I assume wouldn't trigger this file size warning.

    I think kwrite has that problem too, and gedit's (shudder) limit for when it tells you to fuck off seems to be around 4KB. 🐠



  • @topspin Actually ... why 125 GiB? What happened missing to the (128-125) = 3 GiB?


  • Discourse touched me in a no-no place

    @topspin said in WTF Bites:

    That's about line length though, and you can get absurdly long lines which would make it choke even with a 100KB file, which I assume wouldn't trigger this file size warning.

    Line length problems tend to revolve around a) calculating the metrics for the line, especially with word wrapping, and b) doing highlighting, which usually involves a lot of regexps and is done a line a time. With a very long line, both of those things can take a lot longer than normal.



  • @cvi said in WTF Bites:

    @topspin Actually ... why 125 GiB? What happened missing to the (128-125) = 3 GiB?

    More like, how did he get an extra 5 GiB for free?
    128 GB === 119.2 GiB

    Edit:
    P.S.:



  • @cvi said in WTF Bites:

    @topspin Actually ... why 125 GiB? What happened missing to the (128-125) = 3 GiB?

    It's the free and reserve blocks pool. Every flash memory unit needs those.


  • BINNED

    @acrow said in WTF Bites:

    @cvi said in WTF Bites:

    @topspin Actually ... why 125 GiB? What happened missing to the (128-125) = 3 GiB?

    More like, how did he get an extra 5 GiB for free?
    128 GB === 119.2 GiB

    Edit:
    P.S.:

    Probably some funky mixture of binary and decimal.

    6EDD1CFD-5A3F-462B-BCB5-1AB475324C68.jpeg


  • Banned

    @topspin said in WTF Bites:

    qtc_open.png

    Welcome to the 90s! :airquotes: HUGE :trump: :airquotes:

    Depending on how the program works internally, it may take gigabytes of RAM to open couple-megabyte text file. Some editors allocate a single big drawing surface the size of the entire file all at once. Some are a bit smarter and only allocate a perfectly square surface wide enough to fit the longest line in the file, sometimes rounded up to the nearest power of 2. Either way, memory usage gets stupidly high very fast. Most text editors really weren't made with the ability to edit files over 100k lines long in mind.


  • ♿ (Parody)

    One part of my job is keeping an eye on the lady whose main job is writing reports. She does a good job with the ins and outs of formatting with our reporting software and mostly understands sql. But I do a review whenever she closes a ticket.

    There was one recently that had something like or (foo = 1 or foo = 0) where foo will only ever equal 1 or 0 (Oracle boolean). So I told her, basically, WTF is this shit? It makes no sense. Take it out.

    Got another, similar report today and guess what it has? :headdesk:


  • BINNED

    @boomzilla
    She is just preparing for the arrival of Tri-state Boolean alians


  • Discourse touched me in a no-no place

    @Luhmann said in WTF Bites:

    She is just preparing for the arrival of Tri-state Boolean alians

    FILE_NOT_FOUND here we come!



  • Beware of that new DoS method:


  • BINNED

    @dkf
    It's SQL so a good old NULL could do the trick.



  • @acrow said in WTF Bites:

    More like, how did he get an extra 5 GiB for free?
    128 GB === 119.2 GiB

    Don't you still buy RAM in multiples of gibibytes by default, though? Isn't it just harddrives/ssds/etc that went retard and you actually buy multiples of gigabytes?



  • @Bulb said in WTF Bites:

    @cvi said in WTF Bites:

    @topspin Actually ... why 125 GiB? What happened missing to the (128-125) = 3 GiB?

    It's the free and reserve blocks pool. Every flash memory unit needs those.

    But we're looking at RAM here, aren't we?


  • BINNED

    @cvi said in WTF Bites:

    @acrow said in WTF Bites:

    More like, how did he get an extra 5 GiB for free?
    128 GB === 119.2 GiB

    Don't you still buy RAM in multiples of gibibytes by default, though? Isn't it just harddrives/ssds/etc that went retard and you actual multiples of gigabytes?

    The calculation above suggests it’s multiples of mebibytes. (How I hate that word. Binary megabytes. Fuck you, manufacturers)
    At the hardware level, I’d assume they’re at least organized in KiB multiples. But really I have no idea what the hardware does, the OS has pages that are usually 4KiB multiples though.



  • @topspin said in WTF Bites:

    qtc_open.png

    Welcome to the 90s! :airquotes: HUGE :trump: :airquotes:

    Hah! By sheer coincidence, I was editing a 1.4GB text file last night. Notepad++ was choking and becoming unresponsive for a couple of minutes at a time just trying to move the cursor around, but vim handled it just fine.

    Why was I editing such a big file? I finally got around to recovering the 15 years of email destroyed by Thunderbird (:trwtf:) while trying to move a few mails between folders a few months ago. I had saved a copy of the local cache, which is in mbox format. Thunderbird's "Local Folders" storage also uses mbox format, so recovering the emails (though not as convenient as having them on the IMAP server) was simply a matter of creating an (empty) INBOX folder under "Local Folders", copying the cache file over the AppData\Roaming\Thunderbird\Profiles*profile*\Mail\Local Folders\INBOX file it just created, blowing away the INBOX.msf it just created, and letting it rebuild the .msf from the contents of the INBOX. Unfortunately, it doesn't account for the possibility of the string "From " occurring at the start of a line in the message text, so it created a bunch of bogus emails. I had to edit the INBOX to escape those, and there were many of them, without accidentally escaping any of the 30000+ occurrences of "From " that serve as start-of-message indicators in mbox files.


  • Java Dev

    @topspin said in WTF Bites:

    qtc_open.png

    Welcome to the 90s! :airquotes: HUGE :trump: :airquotes:

    sys_load.png

    Go ahead, I think it'll be fine.

    vim generally gets sluggish for me around the 1gb mark. So if my log files are larger than that I either pre-filter them or switch to less.



  • @cvi said in WTF Bites:

    @Bulb said in WTF Bites:

    @cvi said in WTF Bites:

    @topspin Actually ... why 125 GiB? What happened missing to the (128-125) = 3 GiB?

    It's the free and reserve blocks pool. Every flash memory unit needs those.

    But we're looking at RAM here, aren't we?

    I suppose you are right. I got side-tracked by the preceding comment mentioning non-binary units and ass-u-me'd it's a disk and didn't check the original image too carefully.

    If it's RAM, could the 3 GiB be loaned out to a graphic card and/or some other peripherals?

    … checking here, I have MemTotal: 32750700 kB (that Should™ read KiB), which is 803732 KiB short of 32 GiB, and additionally a WeirdNumber™ (I am just using the integrated graphic card, so it does not have its own memory).



  • @PleegWat said in WTF Bites:

    vim generally gets sluggish for me around the 1gb mark. So if my log files are larger than that I either pre-filter them or switch to less.

    I believe it can handle even more if you turn off the swap file, and with it undo.


  • Java Dev

    @Bulb said in WTF Bites:

    @PleegWat said in WTF Bites:

    vim generally gets sluggish for me around the 1gb mark. So if my log files are larger than that I either pre-filter them or switch to less.

    I believe it can handle even more if you turn off the swap file, and with it undo.

    I'd always assumed it's a RAM problem (only 6gb on that VM). Regardless, when those files grow that big vim not handling them well is not the only problem.


  • Notification Spam Recipient

    @Luhmann said in WTF Bites:

    @boomzilla
    She is just preparing for the arrival of Tri-state Boolean alians

    I was going to say null


  • BINNED

    @Tsaukpaetra
    Empty string just punched you in the groin


  • Notification Spam Recipient

    @Luhmann said in WTF Bites:

    @Tsaukpaetra
    Empty string just punched you in the groin

    Can Oracle's ,binary column type hold empty strings??!? :wtf_owl:


  • BINNED

    @Tsaukpaetra
    No idea but given my experiences and knowing you I wouldn't count on it for it to never be True.


  • Considered Harmful



  • @Bulb said in WTF Bites:

    checking here, I have MemTotal: 32750700 kB (that Should™ read KiB), which is 803732 KiB short of 32 GiB

    Hmm. I have "MemTotal: 32814020 kB", or 740412 KiB short of 32 GiB (with a dedicated GPU, though). Strange.



  • @Applied-Mediocrity FTJTMIWWRL™

    ruined_the_joke.png


  • :belt_onion:

    Wife is trying to install Adobe Acrobat Reader. Multiple installation attempts all fail with typical cryptic bullshit error message.

    Apparently, the installer creates a directory, something like C:\Users\username\AppData\Local\Adobe\Acrobat\temp\ and unpacks all it's files into that directory. But then, when it tries to install, it fails. Fortunately, I'm familiar with some of the fuckery that Windows 10 likes to pull, so I go to that directory, check file permissions and

    What The Fucking Fuck

    Nobody has access. Manually set file permissions to full read/write access and installer now works.

    Dear Microsoft and/or Adobe: How to you fuck this up? How fucking retarded are you? Are you the same person who randomly sets file permissions on the Start Menu directory so that programs can't create shortcuts there when they install? Can you please kill yourself?


  • Banned

    @El_Heffe my favorite permissions bug is when you create a new folder in a directory where you have create but not delete permissions.


  • I survived the hour long Uno hand

    @El_Heffe
    $5 says it was some old antivirus with a user as QA bad update.


  • Considered Harmful

    cbdd87b4-f05e-4815-8ab2-159e216c6834-image.png


  • Considered Harmful

    I could make a whole thread about dumb shit people do on Among Us. :kneeling_warthog:


    Filed under: It's not like threads are free.


  • 🚽 Regular

    @Gąska said in WTF Bites:

    @El_Heffe my favorite permissions bug is when you create a new folder in a directory where you have create but not delete permissions.

    I remember there was a server somewhere where I kept an empty directory because I add permission to copy, but not create.

    I created the initial empty directory by copying an existing non-empty directory and deleting the files inside.

    Not 100% sure, but I think I might have kept an empty file as well for the same reason.


  • BINNED

    From MSDN:

    The Universal C Runtime Library (UCRT) supports most of the C standard library required for C++ conformance. It implements the C99 (ISO/IEC 9899:1999) library, with certain exceptions:

    • strict type compatibility in <complex.h>.
    • aligned_alloc, which will probably not be implemented because the Windows operating system doesn't support aligned allocations. Use the non-standard _aligned_malloc, instead.
    • ...

    WTF does it mean that "Windows operating system doesn't support aligned allocations"?! And if it won't be implemented, why did you implement it under a different name (that isn't compatible with free)?



  • @HardwareGeek said in WTF Bites:

    Describe how to debug a test failure. Provide as much technical detail as possible.

    Step 1: Get reproduction steps from the tester who performed the failing test.

    If technical issues make the accomplishment of the first step impossible, due to the nonexistence of any tester to ask questions of,

    fbc8670d-36b2-4bb5-b011-baea68b462e5-image.png


Log in to reply