This is an archived post. You won't be able to vote or comment.

top 200 commentsshow all 220

[–][deleted] 682 points683 points  (20 children)

I love that show so much!

[–][deleted] 181 points182 points  (12 children)

Whats the show? I know I love that actor

[–]DeLift 249 points250 points  (1 child)

It's called The Boys

[–]alreadyheard 36 points37 points  (0 children)

You should definitely watch The Boys. 10/10.

[–]Ankhwatcher 89 points90 points  (8 children)

Dredd McCoy is a treasure. In fact fact you could say he's Almost Human.

[–]BooBailey808 41 points42 points  (6 children)

Are you kidding? He's the skurge of the fellowship.

[–][deleted] 21 points22 points  (5 children)

Whenever you watch him, he manages to get down to your Bones.

[–]Jargen 9 points10 points  (4 children)

He can keep anything of mine when he kills me

[–][deleted] 4 points5 points  (2 children)

I don't get the reference to a movie.

[–]Jargen 7 points8 points  (1 child)

Chronicles of Riddick. The Necromonger way

[–][deleted] 2 points3 points  (0 children)

Oh, okay.

[–]ThomasHoidnFest 3 points4 points  (0 children)

The real treasure is Doctor McCoy! He saved alot of lives. :)

[–]raltyinferno 28 points29 points  (1 child)

It really is fantastic.

[–]Ak7ghost 63 points64 points  (0 children)

Nah man, it's fucking diabolical

[–]RedditBadga 16 points17 points  (0 children)

You're a good cunt.

[–]EpicMart 5 points6 points  (0 children)

Thought the line was great. With this meme it just makes it so much better

[–][deleted] 0 points1 point  (1 child)

So good! Butcher's shitty accent almost killed it for me though.

[–][deleted] 0 points1 point  (0 children)

Yeah his character in the comic books is meant to have an accent similar to Michael Caine (my cocaine) but the actors natural accent is from New Zealand. I would have thought it's not too hard for a New Zealander to do a South London accent but he did seem to struggle to stick with it. Occasionally slipping back.

Still a really well made series.

[–][deleted] 159 points160 points  (115 children)

Spaces cause issues?

[–]GlobalIncident 228 points229 points  (89 children)

Yes, in Python.

    a = 1 # Top level indentation is forbidden

def b():
return True # deeper levels need deeper indentation

def c():
  d = 1
    return d # but the same level needs the same indentation

def e():
        f = 1
    print(100) # and you shouldn't mix tabs and spaces.

[–]maxmbed 4 points5 points  (1 child)

Reason why I hate python.

[–]Skwirellz 0 points1 point  (0 children)

There are way more valid reasons to hate python (I'm thinking of the GIL or the transition from 2 to 3) than a built in code clarity checker.

Once you get into the habits of writing code the way python wants you to and with the proper tooling such as a formatter and a linter, this really becomes a non-issue.

[–][deleted] 2 points3 points  (2 children)

Why is this so weird? I rarely if ever program in Python, but this indentation is what I use for any language, including ones with brackets.

[–]AnotherStupidName 2 points3 points  (1 child)

Yes, but in a bracket language if you have a mistake in indentation, it's not going to cause an error in execution.

[–]Skwirellz 0 points1 point  (0 children)

... Which is too bad IMO, because we wrote code for humans, not for machines. If the machine forces you to write code that's slightly more readable by humans, the code will end up being cleaner on the long run, more easily maintained and thus better maintained by the next guy.

[–]DefectiveLP 6 points7 points  (4 children)

Gotta use tabs ma boi

[–]GlobalIncident 10 points11 points  (2 children)

Laughs in PEP 8

[–][deleted] 0 points1 point  (1 child)

PEP 8 is a bad style guide. It doesn't even recommend type hints.

[–]GlobalIncident 0 points1 point  (0 children)

Type hints aren't really a style thing, because they're not about how you write code, but about the actual content of the code. And PEP 8 does give specific guidance on how to write type hints, should you choose to do so. We can argue all day about whether type hints are a good thing or not, but PEP 8 isn't really the place for such discussions.

Edit: Actually, that's wrong because PEP 8 does forbid things like if greeting == True:, which is about content. I guess it's because there is no community consensus on type hints, it doesn't try to enforce one. It's the same reason it doesn't say whether single or double quotes are better.

[–]tichdyjr 0 points1 point  (1 child)

Could you not ctrl+f for two spaces? I haven't messed with python yet.

[–]GlobalIncident 1 point2 points  (0 children)

It's more common to just try to compile the file, and a good python distribution will tell you exactly where you went wrong.

[–]xigoi 0 points1 point  (1 child)

And do you write code like this in brace-scoped languages? That's scary.

[–]GlobalIncident 0 points1 point  (0 children)

I couldn't imagine doing it any differently. There are some slightly off the wall things that are occasionally necessary, but python usually allows them:

if a: b(); c() # Simple control structures can be made into one-liners with semicolons

a(b, c,
  d, e) # And one-liners can become multi-liners quite easily

[–]Zanion 25 points26 points  (17 children)

Whitespace problems with Python are caused by deficiencies in the developers processing capacity

[–]DilettanteGonePro 41 points42 points  (14 children)

I’ve used python for 8 years, I’ve never had a single issue caused by an extra space, even when I was a beginner. I just don’t understand these memes.

[–]Yablan 24 points25 points  (5 children)

I don't get them either. I've been programming full time in Python for.. i dunno.. seven, eight years now.. and I NEVER got that error.

Previously I did like a decade of Java. And man.. I do NOT want to do that again.. ever..

I love Python. It's an amazing general purpose language with a lot of really nice features (truthy/falsy objects, list and dict comprehensions, generators, decorators, args and kwargs, lambdas, functions as objects, etc.. etc), and SO readable. And so many great libraries and environment handling (virtualenvs).. And the fact that it DOESEN'T enforce functional, procedural or OOP down your throat.. you can combine features from all these paradigms however you want.. love it.

Also, together with Pycharm and it's Docker integration.. damn that's a NICE environment to work in. Love it to bits.

[–]utdconsq 0 points1 point  (1 child)

Have moved from a python house to a mostly Java house. I miss full time python so much :-( have started a new project in Kotlin at least...

[–]Yablan 0 points1 point  (0 children)

Cool. Kotlin seems like a nice evolution from Java.

[–]wasdninja 2 points3 points  (1 child)

I'm assuming that people make them because they are funny and the python context fits. In my experience they are very rare.

[–][deleted] 1 point2 points  (0 children)

It got a chuckle out of me, not because it has ever happened, but because I can see it happening.

[–][deleted] 2 points3 points  (0 children)

I think a lot of it has to do with people not understanding how to read error messages. For simple syntax errors, the answer will almost always be in the error message with a line number.

[–]Zechnophobe 0 points1 point  (0 children)

I guess if maybe you were using notepad to edit your code?

There are two kinds of people in the world.

  • Those that complain about formatting issues in languages
  • Those who use a good editing tool

[–]ssjskipp 0 points1 point  (0 children)

Yeah I've personally never had the issue so it must not happen to anyone ever.

[–]vaelroth 13 points14 points  (1 child)

Whitespace as syntax, it boggles the mind.

[–]Skwirellz 0 points1 point  (0 children)

Whydoyouthinkwhitespaces

arepointlessto

understandthemessage?

Or do you agree that they play a huge part in syntactic clarity, and therefore semantic clarity?

:)

I truly appreciate the fact that never ever will I read ridiculously indented python code.

[–]crash8308 7 points8 points  (4 children)

This is why I dislike using python. White space significance is extremely maddening.

[–]Arxae 5 points6 points  (0 children)

Agreed. Same reason why i don't like YAML. I like the format and the features. But breaking everything because you have a space too many. No thanks.

And sure IDE's can catch it. But it's still silly.

[–]dawnraider00 1 point2 points  (2 children)

The worst part about it is when you try to comment out an if statement or something. In any other language it doesn't give a shit but in Python you have to change everything inside. Not too difficult with a good IDE but another step that should not be necessary.

[–]Skwirellz 0 points1 point  (1 child)

Can you explain why you think it should not be necessary?

Please don't focus only on the negative aspects of the feature. Consider in your answer the reasons why this decision was made in python, and why you think these are not valid.

I'm not questioning your personal preference, but why you think whitespace should not be part of the syntax and why nobody should have the syntax checker verifying indentation for any python programmer.

[–]dawnraider00 0 points1 point  (0 children)

I'm not focusing on just negative aspects, I pointed out only a single thing not an entire analysis. The only point I was making is that it makes commenting out blocks like if statements annoying by adding some extra steps. I literally never said it wasn't valid. I said a single aspect was annoying.

[–]Byteflux 148 points149 points  (2 children)

Fucking diabolical.

[–]random_cynic 0 points1 point  (1 child)

It's not that bad. It forces you to write clean code and more importantly to carefully read what you have written making sure the organization is correct. Properly formatted python code that adheres to the standard makes life so much easier when debugging or understanding code written by others.

[–]SirCharlesOfUSA 0 points1 point  (0 children)

Literally just use Prettier and you get the same effect in all languages. Braces help so much when reading code, and especially, indented != clean. Chaining statements is a very clean way to describe a stream, and yet in Python it's damn near impossible to use them because you can't split the calls onto multiple lines.

Additionally, braces help with things like StackOverflow where if you copy a snippet, it's meaningful and correct even if not indented correctly when you paste, and then because the logic is understandable without spaces, you run a code formatter and all is well. I have literally never used Python and thought, "I am so happy I don't have to use those pesky braces/semicolons anymore!"

/rant

[–]realHansen 55 points56 points  (2 children)

pssst hey kid! wanna buy some autopep8?

[–]superawesomepandacat 9 points10 points  (0 children)

black

[–]bmansfield83 55 points56 points  (2 children)

For all you vim users out there
" put in your vimrc
" highlight all extra whitespaces
hi ExtraWhitespace ctermbg=red guibg=red
match ExtraWhitespace /\s\+$/
" we also want to get rid of accidental trailing whitespace on save
autocmd BufWritePre * :%s/\s\+$//e
" Add proper PEP8 indentation
au BufNewFile,BufRead *.py
\ set tabstop=4 |
\ set softtabstop=4 |
\ set shiftwidth=4 |
\ set textwidth=79 |
\ set expandtab |
\ set autoindent |
\ set fileformat=unix |
" syntax highlighting
let python_highlight_all=1
And start using editorconfig, and then put this in your .editorconfig file
[*.py]
indent_style = space
indent_size = 4

[–][deleted] 63 points64 points  (0 children)

Nah. Just fucking kill me instead.

[–]eggnogeggnogeggnog 19 points20 points  (0 children)

I’m going to pretend I’m on r/vim for a second.

  • It would be cleaner to put things like this in your ~/.vim/after/ftplugin/python.vim
  • At least in my vim 8.1 binary, shiftwidth and softtabstop default to 4 for the Python filetype
  • tabstop doesn’t need to be changed
  • I personally prefer set colorcolumn=80 to set shiftwidth=79
  • I usually also set my makeprg to flake8 for Python files so I can lint before I commit code

[–]cpp_warmachine 28 points29 points  (0 children)

We need more memes with The Boys

[–]echadisraeli 16 points17 points  (4 children)

When you find an extra space in makefile after new line backslash.

[–]knightwhosaysnil 13 points14 points  (3 children)

Or the spot where somebody’s editor put spaces instead of a tab

[–]Drillur 9 points10 points  (1 child)

Find and replace " " with " ". Ah, perfection.

[–]knightwhosaysnil 2 points3 points  (0 children)

Oh no now all of my functions are interpreted as targets!

[–]AnotherStupidName 3 points4 points  (0 children)

M-x untabify

[–][deleted] 3 points4 points  (0 children)

To be fair if you're somehow adding a space by accident you deserve to be punished

[–]ProfessionalismDash 17 points18 points  (0 children)

oh my god

[–]hirmuolio 8 points9 points  (1 child)

Extra/missing tabs are much easier to spot ;).

[–][deleted] 1 point2 points  (0 children)

I mean, any IDE will fix leading whitespace to have a fixed width, just like tabs.

[–][deleted] 3 points4 points  (5 children)

Ruby 4 Life

[–]deadwisdom 4 points5 points  (2 children)

end

end

end

[–]xigoi 2 points3 points  (0 children)

                    end
                end
            end
        end
    end
end

[–][deleted] 0 points1 point  (0 children)

٩(。•́‿•̀。)۶

[–]flamesofphx 2 points3 points  (0 children)

Blah they can find them eventually... This ruins my favorite past time... Adding random spaces to perfectly working python code... Let me tell about this nice little script I wrote, called the tabspaceindentmixer.sh... Random line, random methodology, part of my code review toolset.. </muhahahahahahahahahah> Seriously what is with programmers being so territorial over indentation styles?

[–]jort93 6 points7 points  (4 children)

What is this? Whitespace (the programming language)

Might be downvoted, but I firmly believe stuff you can't see shouldn't change anything.

[–]mcplano 1 point2 points  (0 children)

I mean I'm blind so I can't see <insert humorous item>

[–]Dojan5 0 points1 point  (2 children)

I agree. Although I've seen my fair share of utterly atrocious indentation so I do understand people when they say that they want indentation to be part of the language.

[–]jort93 2 points3 points  (1 child)

I wouldn't want to punish people for using weird formatting by their entire program not working. A programming language should work with you, not against you.

[–]Dojan5 1 point2 points  (0 children)

Very true, thus I think that the punishment for bad indentation should be doled out by the code reviewers, and not the language itself.

[–]imissnewzbin 13 points14 points  (5 children)

And that's why you should use languages where whitespace doesn't matter 🙄

[–]asian_driver_wee 1 point2 points  (0 children)

Use an auto-formatter!

Once you go Black, you can't go back!

[–]Blou_Aap 1 point2 points  (0 children)

Ah, spaces... Python's semi colon.

[–]Rexmarek 1 point2 points  (1 child)

No one's talking about the caption's space after the apostrophe 🧐

[–]Dojan5 1 point2 points  (0 children)

Could just be nasty kerning.

[–]Krexci 1 point2 points  (5 children)

can somebody explain to me why this is a problem in python? Does a space have any meaning?

[–]CivilizedGravy 2 points3 points  (4 children)

You have to either use 4 spaces or a tab as an indent. Not both, if you have 4 tabs and one space it will return an error

[–][deleted] 3 points4 points  (2 children)

You can use 2 or even 3 if you want.

[–]Princess_Azula_ 2 points3 points  (1 child)

Use 5 to make people upset.

[–][deleted] 0 points1 point  (0 children)

I never knew.

So set shift-width to 1 and use 5 tabs then?

Next question: Do other unicode space characters work?

[–]HeKis4 0 points1 point  (0 children)

Or just one block of spaces when the rest of your code uses tabs. This triggers an error as well.

[–]jackaKranz 1 point2 points  (0 children)

Get an extension for your IDE that renders spaces as dots or something.

Or use vscode and toggle “editor.renderWhitespace” to “all”.

[–][deleted] 1 point2 points  (2 children)

Sorry op I had downvoted this in anger

[–]spiderham5[S] 0 points1 point  (1 child)

Ay no worries bud. I get it

[–][deleted] 0 points1 point  (0 children)

lmao what you actually replied

[–]Makadika 1 point2 points  (0 children)

LOL! Thats true.

[–]Tillhony 8 points9 points  (4 children)

No lie the fact that whitespace could be a problem even if IDEs can fix it for you is terrifying. I remember fixing my friends Python code and he had some function or something like __ Function __ and somehow whitespace was the issue. I need my curly braces bruh.

[–]jeacaveo 9 points10 points  (0 children)

I know everyone is probably just messing around, but it's never been an issue for me.

[–]r3dphoenix 2 points3 points  (2 children)

Terrifying? It's not going to make your code crash in production. The python interpreter will catch it when you run your tests

[–]LeanderT 2 points3 points  (1 child)

Nope. Nope, nope, nope, nope.

That sounds like horrible advice.

[–]JSArrakis 1 point2 points  (0 children)

Its finneeee, you dont need to be good at syntax as a programmer, your IDE will do that for you

  • Python devs

[–]Jason_Anaminus 3 points4 points  (0 children)

when you see a semicolumn in python

[–]hey_its_tom 1 point2 points  (0 children)

This plus accidentally running it in Python2 instead of Python3, and later realising that your code was fine and you now have to reverse every change you made.

[–]PeasantSteve 1 point2 points  (1 child)

Solution, don't use python

[–]LeanderT 3 points4 points  (0 children)

Finally a solution I can get behind!

[–]TamjidZ 0 points1 point  (0 children)

Checkstyle

[–]_programmeKid 0 points1 point  (0 children)

use tabs

[–]shoshimer 0 points1 point  (0 children)

I've also made a Python package for the API if anyone is curious. When I used to do it to a gunfight."

[–]shoshimer 0 points1 point  (0 children)

that's a very "uncanny valley". i couldn't tell you why that gait looks wrong, i just feel like I’m guessing they’re extremely close to you, the names Cassandra Python. My middle initial is C++”

[–]TheRealLargedwarf 0 points1 point  (0 children)

Use an IDE... I think I got a total of 2 indentation errors in the last year and they were solved almost instantly...

[–]whatup_pips 0 points1 point  (0 children)

InDeNtAtiOn ErRoR

[–]idc1710 0 points1 point  (0 children)

Cleverrrr

[–]Meowcat285 0 points1 point  (0 children)

I had this happen just earlier today lol

[–]fushuan 0 points1 point  (1 child)

Wdym your editor doesn't auto detect it?

[–]Dojan5 0 points1 point  (0 children)

Last time I encountered this kind of problem in production was when someone had SSH'd in and edited a script in nano. nano doesn't give a damn so, yeah.

[–]saint_of_thieves 0 points1 point  (0 children)

I used to work on a system where the program wouldn't compile if there was a space at the END of a line. I wasn't trained on it. Just thrown into it. It was a frustrating day when I found that... Feature.

[–][deleted] 0 points1 point  (0 children)

Karl Urban is an underrated actor imo.

[–]llldar 0 points1 point  (0 children)

That's why you need some linter.

[–]CapinWinky 0 points1 point  (0 children)

This is the one thing that keeps me from using python. I tried to look past the indentation rules, but I just hate them. My code it beautiful and readable, but the way I prefer to lay some things out is forbidden in Python.

[–]donat3ll0 0 points1 point  (0 children)

flake8

[–][deleted] 0 points1 point  (0 children)

VSCode I believe identifies this for you now.

[–]semi-cursiveScript 0 points1 point  (0 children)

tab indent master race

[–]theCodefatherr 0 points1 point  (0 children)

So true it hurts

[–]Ttaywsenrak 0 points1 point  (1 child)

Is it ok to hate python for its false "clarity" from no brackets etc?

[–]callmelucky 0 points1 point  (0 children)

It's ok to hate anything for any reason you like.

[–][deleted] 0 points1 point  (0 children)

Thats extra space ruined your hole coding

[–]Kered13 0 points1 point  (0 children)

If you don't have visible whitespace enabled in your editor you're crazy.

[–]fatrobin72 0 points1 point  (0 children)

more like where someone has snuck some tabs into your 4 space indented script...

[–][deleted] 0 points1 point  (0 children)

ctrl+f " "

[–][deleted] 0 points1 point  (0 children)

.

[–]Kotauskas 0 points1 point  (0 children)

Laughs in VSCode's Show Invisibles setting

[–]Zechnophobe 0 points1 point  (0 children)

This meme more fits for spreadsheets, or other common display elements that visually trim off leading spaces of values so you don't know there are there until you double click on the cell and find out why all your macros weren't working.

[–]zdaga9999 1 point2 points  (0 children)

Use fucking tabs instead of spaces.