Cannot save changes (API_ERROR: Reference update failed - "UNPUBLISHED_ENTRY_PERSIST_FAILURE")
See original GitHub issueDescribe the bug
I am getting an error when I try to save some changes in the CMS of a site deployed on Netlify.
The error I get when I make a change and click the Save button is this: Failed to persist entry: API_ERROR: Reference update failed
To use GitHub as the authentication method for the CMS (so that my GitHub user can login into the CMS), I followed the instructions of the docs. The configuration can be seen here: https://github.com/Petrolog-IT/one-click-hugo-cms/blob/master/site/static/admin/config.yml
backend:
name: github
repo: Petrolog-IT/one-click-hugo-cms
branch: master
As the docs mentioned, I created an OAuth app on GitHub and added the Client ID and Secret in the appropriate settings page of Netlify:
I can login into the CMS of the site deployed on Netlify with the Petrolog-IT
GitHub user successfully. I can also delete things from the CMS successfully. But I cannot save any changes.
To Reproduce
Expected behavior
Create a commit with the changes.
Screenshots
Applicable Versions:
- Netlify CMS version: 2.9.7
- Git provider: GitHub
- OS: Ubuntu Xenial 16.04
- Browser version Version 75.0.3770.142
- Node.JS version:
CMS configuration
https://github.com/Petrolog-IT/one-click-hugo-cms/blob/master/site/static/admin/config.yml
Additional context
These related issues didn’t help:
Issue Analytics
- State:
- Created 4 years ago
- Comments:15 (5 by maintainers)
I added this to the list of API_ERROR solutions and workarounds: https://github.com/netlify/netlify-cms/issues/2827
This is solved by deleting the
cms
branch from the repo. I remember it from a previous issue. I’ll check why having a branch with that name breaks editorial workflow