Back
Internal curl errors has occurred within the executor! Error Number: 52. Error Msg: Empty reply from
- 0
- Self Hosted
- Functions

I'm getting the following error very frequently now:
Internal curl errors has occurred within the executor! Error Number: 52. Error Msg: Empty reply from server\nError Code: 500
The whole is in the try-and-catch block where in catch I'm returning json response with a 500 status code.
TL;DR
Developers are encountering an error with empty replies from the server when using the curl executor. The issue arises within the try-catch block. A potential solution could involve investigating the environment variables or checking for any issues within the curl requests.
Could you post your code, leave out anything not important to the question at hand

TypeScript
export const errorRes = (
res: any, error: any, message: string, code: number) => {
error(message);
return res.json(
{success: false, error: message},
code
)
};
export default async ({req, res, log, error}: Context) => {
let doc: string | null = null;
let client;
try {
if (
!process.env["APPWRITE_FUNCTION_API_ENDPOINT"] ||
!process.env["APPWRITE_API_KEY"] ||
!process.env["APPWRITE_FUNCTION_PROJECT_ID"]
) {
return errorRes(res, error, 'ENV Variables missing.', 500);
}
/* --------------------- */
// Do operations
/* --------------------- */
return res.json({
success: true,
file_id: uploadedFile.$id,
});
} catch (err: unknown) {
if (err instanceof Error) {
error(err.stack);
}
return errorRes(res, error, 'Something went wrong internally. Message: ' + err, 500);
}
};
Recommended threads
- How can I check which version of node-ap...
Hi everyone, I deployed a Function on Appwrite with the following in my package.json: ```"dependencies": { "node-appwrite": "*" }``` Since Appwrite automat...
- I can't add relationship attributes on m...
How can I make it work in selfhosted Appwrite?
- Various Issues with Selfhosted Instance
When Creating sites, applications and messages i get different errors in Appwrite: When adding Site: Cannot access offset of type string on string When buildi...
