fixed accessing uninitialized variable
fixed parse error
update py