I am updating a doc using the SDK and the appwrite console, updating one of the doc is working just fine but another one fails with the following error:
"message": "Server Error",
"code": 500,
"type": "general_unknown",
"version": "0.12.125"
}```
any thoughts?
please make sure to:
- put descriptive titles so that it helps with searching and when looking at the list of posts
- format multiline code with backticks
- include all relevant tags
would you please provide your project id?
500 error when updating document
there's some invalid value in one of your relationship attributes
is there a way to see the logs or to find out which attribute it is?
one of these:
$createdAt: 2024-03-21 04:40:29.824,
$id: 65fbba3dc85bb7284ceb,
$permissions: [],
$updatedAt: 2024-03-21 04:40:29.824,
author: [Filtered],
content: This is my second post,
likes: 0,
masjid: ,
parent: null,
related_masjid: [],
replies: 0,
tags: []
I can't tell much more than that
what's your payload?
here is the update func:
process.env.NEXT_PUBLIC_APPWRITE_DATABASE_ID,
collections.posts,
postId,
{
likes: newLiks
}
);```
I removed the relationships and added it again and it solve the problem. the author attribute had a relationship with the user collection, changing it from author to user (same name as the related collection) fixed it. Does this mean that the relationship attribute should be name exactly the same as the related collection?
Sorry I don't understand
Recommended threads
- Helping in unblock my account
I deleted my Appwrite Cloud account that was linked via GitHub. Now I activated my GitHub Student Pack and want to sign up again using the same GitHub account, ...
- Not allowed permission to upsert a prese...
```js const presenceID = ID.unique(); setPID(presenceID); const presence = await presences.upsert({ presenceId: presenceID, status: "online"...
- Finding job
Hi. I am a full-stack developer with experience in developing scalable and user-friendly web applications. I handle both front-end and back-end development, im...