2
Parzi
4y

This is a massive tossup between RandNoRepeat( from TI-BASIC (returns an int between 2 passed params but tracks what's been given from that range this power-on, meaning if the range is too low IT ENDS UP HANGING THE FUCKING CPU IF YOU RUN OUT OF NUMBERS and it also rolls over and over so it's slow as shit in general) or Python forgetting how the fuck if statements work.

Comments
  • 1
    What do you mean by "forgetting how if statements work" ? I always like to hear about languages behaving weirdly
  • 0
    @CptFox You can fulfill an entire if statement, and *occasionally*, Python will still skip it. No idea what causes it, no pattern to it (aside from the fact that VSCode makes it ***infinitely worse***, as VSC makes Python unstable in general) and it may or may not just work an hour later.
  • 3
    @Parzi weird. You sure that's not a race condition messing you up? Race conditions like to mess with people '^'
  • 0
    @CptFox a test case of
    ```
    i = True
    if i:
    print("True")
    else:
    print("False")
    ```
    and nothing else shouldn't sometimes output False when Python's being an asshole.
  • 3
    @Parzi I've used Python for years in some fairly extreme environments (AST editing and code generation on the fly, multiprocessing servers, green threads) and I've never seen that happen. It would literally break basic guarantees that the language makes and the odds of that happening are smaller than most compiler bugs, because it would be caught immediately. The problem must lie elsewhere. (Reasoning: the more basic a problem is, the easier it is to find effects of it)

    VSC makes python unstable - what? It's literally just calling the Python interpreter via a script.
  • 0
    @RememberMe i can get undefined behavior on a simple "printf-then-exit" C program sometimes, so that's not a shock that "oh that's impossible" in python, honestly.
    Also vscode consistently ate shit on one or another version of xemu when it was fine in IDLE or run via python on the command line. Multiple people watched it happen live. I'll have to see if I can find whichever version it was.
  • 1
    @Parzi again, external problem. No standards-compliant C implementation would do that. That's why said standards exist.
  • 0
    @RememberMe ah, yes... my favorite nonstandard C implementation: GCC.
  • 1
    @Parzi there's no way a compiler as widely used as gcc could have a bug and it would go unnoticed. Not happening. Look elsewhere for your problem.

    Not complying with standards is a major bug. GCC extends beyond standards, yes (hence the usual "gcc is nonstandard") thing, but otherwise is pretty faithful to what the standard says it should do.
  • 0
    @RememberMe sarcasm is great because fucking no one gets it. I can run a simple hello world program I compiled myself 1000 times and 10 or so times it'll segfault or yell about something being undefined or whatever, no matter what I use: GCC, VSCode, whatever the fuck the Microsoft one is called I forgot...
  • 2
    @Parzi well, sarcasm is hard to communicate on text :p

    Again, pretty sure the problem is elsewhere. Try an online REPL like Compiler Explorer or repl.it or something. Try on a VPS or a Raspberry Pi if you have access to those. If you have both Python and C flaking out then the issue is either your hardware or a corrupt system library.

    You could try with clang or msvc if you want but it's pointless probably. One language flaking out is bad enough, two just means it's a fundamental issue somewhere else.

    This is extremely weird because you're running C and Python stuff just by using any common OS. If they were buggy your system would crash immediately. Even weirder that if your hardware or a system lib is buggy then your PC should be crashing pretty much constantly.

    This is assuming your programs are well formed, btw.
  • 0
    @RememberMe to knowledge, the programs are correct, and this has persisted across 2 installs of Win10 and 2 installs of Debian, each time starting fresh. My hardware is missing the AVX instruction set and IOMMUv2 which provides some encryption functions and such, but those wouldn't cause that...
  • 2
    I'm starting to think your hardware has some pretty severe malfunctions (or you live inside a dollar storm), because your examples all sound like extremely severe memory corruption problems
  • 1
    @CptFox solar* storm, darn autocorrect
  • 2
    @Parzi probably a hardware thing as @CptFox says. Basic systems software like interpreters and compilers are usually WAY more reliable than you give them credit for, since so much depends on them.
  • 0
    @CptFox my hardware may be rotting, but most shit works fairly well on it. This'd be plausible if it wasn't fairly stable for, say, gaming...
Add Comment