Unable to find record 'tina/__generated__/_graphql.json'
error?TinaCloud's GraphQL API returns this error when it cannot find a file in your GitHub repository. This may occur under the following circumstances:
tina
folder (and __generated__
subfolder) is not in your GitHub repository remote.gitignore
file excluding ittina
foldertina
folderhttps://content.tinajs.io/content/{tina_client_id}/github/{branch}
where {tina_client_id}
matches the Client ID on the Project in TinaCloud and {branch}
is a valid branchThe local GraphQL schema doesn't match the remote GraphQL schema
error?If you are getting this error in your build logs, it means that the tina/tina-lock.json
in your deployed site doesn't match the version that is in TinaCloud. To resolve it:
tina/config.ts
) does not include any varying information, such as timestamps or random text@tinacms/cli
and tinacms
in your projecttina/tina-lock.json
and push those to the git repository linked in TinaCloudIf you are getting this error when access the TinaCMS interface, it can be caused by a mismatch between the version of tinacms
and @tinacms/cli
on the project. Update both dependencies to the latest versions and run the dev command locally. Commit any changes to the tina/tina-lock.json
and push those to the git repository linked in TinaCloud.
If you receive an error like The specified branch, 'my-branch-name', has not been indexed by TinaCloud
, or see no branches indexed at all, try the following:
tina/config.ts
on the default branchtina/config.ts
. Note, that this value may be set as an environment variable in your CI build processtina/tina-lock.json
file in that branch, committing it, and pushing it to GitHub. This will initiate indexing for the branch, and (after a few minutes) the error should be resolvedThere was a problem saving your document
error?When using TinaCloud without Editorial Workflow, you need to ensure that the TinaCloud App is able to commit to the selected branch of the repository.
If it cannot, you will see an error of the following form:
Tina caught an error while updating the page:Error: Unable to fetch, errors:Error in PUT for src/pages/some-page.md
Video: FAQ - Bypassing GitHub branch protection with TinaCMS (3min)
Generally this happens when there is branch protection on your main branch and TinaCloud is unable to bypass it. Until July 2024, the TinaCloud GitHub app had admin rights to repositories which allowed it to bypass these rules for most repositories.
To fix this issue, either:
Invalid or undefined branch
error?The current branch that Tina is using is invalid or undefined. Double check that the correct branch is selected and it does in fact exist.
You can view the branches that have been indexed by TinaCloud by visiting https://app.tina.io/projects/<your-project-id>/configuration
.
Figure: Branches indexed by TinaCloud
tina directory not pushed to git
error?Everything in the tina
directory (except the __generated__
folder) needs to be pushed up to the git repository. Be sure to add it to your git repository (and make sure you don't have it listed in a .gitignore
). Also make sure that the branch you're trying to use has the tina
directory and is up to date.
API URL is misformatted
errors?The ContentAPI URL isn't formatted correctly. See here for information on how the URL should be formatted.
Invalid
errors?When logging into TinaCloud, the URL of the website you're attempting to login from is sent via the ?origin=
URL parameter. This error can occur when the URL specified in the ?origin=
URL parameter of the auth window does not match one defined within your TinaCloud Site URLs.
To resolve this, ensure that one of the URLs specified in your TinaCloud Site URLs settings exactly matches that shown in the ?origin=
URL parameter.
Figure: URL parameter
Figure: TinaCloud Site URLs settings