I'm using a dictionary created by a search cursor from one feature class to update another feature class with an update cursor. I'm getting an invalid syntax error for the cursor.updateRow(row) and..have no idea why.
There must be something blatant I'm missing, yet I am simply not seeing it. Can someone point out why this code snippet would be providing an invalid syntax error for cursor.updateRow(row)? The format, from what I see, matches all the examples I've found.
with arcpy.da.UpdateCursor(testingSHP, ['SERVICEMXL','STREETADDR']) as cursor:
for row in cursor:
mxLoc = row[0]
oldAddr = row[1]
if mxLoc in svcDict:
print("Looking at row {0} with an address of {1}.".format(mxLoc, row[1]))
row[1] = svcDict(mxLoc)
print("Address is now {0}.".format(row[1])
cursor.updateRow(row)
del cursor
print("Address is now {0}.".format(row[1])
toprint("Address is now {0}.".format(row[1]))