• Register
Welcome to Kodlogs, programming questions and answer website.
0 votes
64 views

Problem :

I'm new to Python & trying to create an application in Python 3.2 and I use tabs all the time for indentation, but even the editor changes some of them into spaces and then print out "inconsistent use of tabs and spaces in indentation" when I try to run the program.
by (6.9k points)  

1 Answer

0 votes

Solution:

It is possible to solve this issue by using notepad++ by replacing Tabs with 4 Spaces:

  1. Choose Search -> Find
  2. Select the Replace tab
  3. In the box named Search Mode choose Extended(\n, \r, \t, \0, \x...)
  4. In the field Find what : write \t
  5. In the field Replace with : press Space 4 times. Be sure that there is nothing else in this field.
  6. Click on the button Replace All

How to replace Tabs with Spaces

Further Readings:

https://github.com/ntasfi/PyGame-Learning-Environment/issues/11

by (36.1k points)  
edited by
...