updated pyScript for changes