How to properly paste Python function block into python console?

Hi i have some questions :

i want to paste block of function into the python console and got a lot of indentation error. Is this a bug or do i miss something ? i’m using 2.79.

I’m new in coding. What is the best IDE for doing interactive debugging regarding building python code/function for Blender ?

Anyone can help ?

class VIEW3D_MT_edit_mesh_looptools(bpy.types.Menu):
	"""    LOOPTOOLS    """
	bl_idname = "" 
	bl_label = "LoopTools"

	def draw(self, context):
		layout = self.layout
		layout.operator("mesh.looptools_bridge", text="Bridge").loft = False
		layout.operator("mesh.looptools_bridge", text="Loft").loft = True


you dont use the console for this. use the text editor.

Thanks, btw i found the problem. The console doesn’t allow me to paste multilie codes which contains empty line. So if i remove that empty line between bl_label and def draw(), then when i paste the code, it works fine.

it should works anyway, it’s just the matter of pasting the code. If you paste it in line by line then has no error. So it’s just a matter how you paste it.