Hi,
I keep getting the error
Traceback (most recent call last):
File "<string>", line 11, in <fragment>
builtins.TabError: inconsistent use of tabs and spaces in indentation (<wingdb_compile>, line 11)
With the lines being
for line in datafile:
pricedata = line.split(",")
newdata[pricedata[0]] = pricedata[6]
I have taken out and put back the indents (tabs) for these lines several times already and still get the same error. I have tried two different IDEs (Wing and Idle) Does anyone have suggestions on what I could be missing
The full code is below.
import os
pricedata = []
newdata = {}
# sets up array and hash for later
symbolfile = open("symbols.txt")
for symbol in symbolfile:
symbol = symbol.strip() #woo woo!
datafile = open(symbol+".csv")
for line in datafile:
pricedata = line.split(",")
newdata[pricedata[0]] = pricedata[6]
os.rename(datafile,symbol+"big.csv")
datafile.close()
newfile = open(symbol+".csv",w)
newfile.write(newdata.items())
newfile.close()