Skip to content
  • Sean Leavey's avatar
    Fix multiline string mis-indentiation caused by Black formatting · 7d34b0ff
    Sean Leavey authored
    Black treats multiline strings (i.e. """text""") like parentheses, so something like
    	parse("""
    		stuff
    	""")
    
    gets turned into
    
    	parse(
    		"""
    			stuff
    	"""
    	)
    
    This happens because Black refuses to add another indentation before the closing """, which
    is reasonable considering not every application will ignore whitespace.
    
    This commit fixes multiline strings to nicely indent again, like so:
    
    	parse(
    		"""
    			script
    		"""
    	)
    7d34b0ff