@Chancerose91,
When you edit with the Visual Playbook Editor (VPE), great care must be taken (oh and the warning message that follows) to make sure you are not selected on the canvas verses the block that you are trying to edit otherwise this happens. If it does, you can immediately revert the playbook back to the original state, however, if you (like you stated) have continued to make changes, reverting would lose your work that you performed. In the screenshot below, you can see the "Full Code" is selected next to function.
When you make a change in the Python Playbook Editor with Full Code, you should see this warning above ...
To revert this block, you just have to click on the revert icon in the lower right hand side as seen in the image below.
This will revert you playbook back to it's former glory. Make sure that you select the blocks that you want to modify verses the canvas or full code view to make any custom code changes.
... View more