We host Octopus locally. Currently we are running version 2021.3.8275. A user was editing a step template and adding a variable. After they saved the change the step template can not longer be edited in the UI. Now we get this.
Thanks for reaching out to Octopus support and I’m sorry to see you’re running into this issue with your step template. We were able to reproduce your error thanks to the template information you sent along. It appears that removing the package reference and saving the step template is what produces this error. You can see in the JSON you sent over that the PackageID is set to null.
Luckily tou should be able to fix this by updating the step template again using the Octopus Swagger UI.
First you should do a GET for the action template to ensure you have the properly formatted JSON.
I have logged a GitHub issue for this which you can watch if you would like to receive updates on the progress. Hopefully this information helps get your template up and running again and please let me know if you have any other questions for me.