Skip to content
Back

Kotlin : io.appwrite.exceptions.AppwriteException: No file sent

  • 0
  • Self Hosted
  • Functions
  • Tools
JamshedAlamQ
16 Jul, 2024, 13:23

Hello Everyone, I'm trying to create and deploy a function through appwrite kotlin sdk. But i'm getting this exception io.appwrite.exceptions.AppwriteException: No file sent . Appwrite is hosted locally.

TypeScript
function.create(
    functionId = "6664b0fb0033b1c47151",
    name = "SayHello",
    runtime = Runtime.KOTLIN_1_9,
    entrypoint = "src/Main.kt"
)

function.createDeployment(
    functionId = "6664b0fb0033b1c47151",
    code = InputFile.fromFile(File(gzipFilePath)),
    activate = true,
    entrypoint = "src/Main.kt",
    onProgress = {
        Logger.i("Progress: $it")
    }
)

It's working fine with cli. but in server sdk i'm getting this exception. Please give me a solution if anyone knows ASAP

Thank you all.

TL;DR
Developers are encountering `io.appwrite.exceptions.AppwriteException: No file sent` when trying to create and deploy a function through the Appwrite Kotlin SDK. The issue arises specifically with the server SDK but not the CLI. The provided code snippets are causing the problem. To fix this, make sure that the function's code is properly included when creating the deployment.
Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more