
kindly assist if you're chanced

Can you check the appwrite console and see if those executions show same response?

okay then

response on client app is same with appwrite console response
@rohit90314

below is the response:
{"Status":"M S- yam"}
despite having separate resquest, response is same...

Please don't tag people just because you need help. Please be patient and wait for a response

Please share your code

ok

serverside or clientside?

user side:
dynamic execution = appWriteLogicExtender.functions.createExecution(
functionId: 'automate_service_sender_', data: json.encode(data));
// showloader = true
showLoaderUpdater(true);
if (kDebugMode) {
print("What is sent to server: ${data.toString()}");
}
execution.then((response) {
// show loader = false
showLoaderUpdater(false);
final decoded = json.decode(response.response);
print("What is gotten from server: ${decoded.toString()}");
});

server side:
Future<void> start(final req, final res) async {
final client = Client();
// // ////////////////////////////////
client
.setEndpoint("xxx")
.setProject("xxx")
.setKey("xxx")
.setSelfSigned(status: true);
dataFromClient = await jsonDecode(req.payload);
res.json({
'Status': getResp.toString(),
});
}```
there are other part of the code and it returns a string statement using the variable **getResp**
expecting separate response but getting same as though it is cached

yes, returned getResp

Something might be wrong with your logic then

I crossed checked before asking for help

but does appwrite cache request?

No

Add a print(req.payload)
to confirm the data is coming in correctly. Add a print(getResp.toString())
before res.json() to confirm the data is going out correctly

if (serciceTypeAndServiceName == "MTN SME") {
if (isMTNSMEAvailable.toString() == "Automated") {
x = "M S- yam";
}}
else if (serciceTypeAndServiceName == "MTN CG") {
if (isMTNCGAvailable == "Automated") {
x = "M C- yam";
}
}```
content of code, I decided to say:
```dart
x = "M S- yam";
and
x = "M C- yam";
in place of main code function to see where error was and discovered there was same response for diffrent request

Sorry I don't understand

if request has
"MTN SME"
The response should be:
x = "M S- yam";
and otherwise
but after gettin
"M S- yam";
for the below:
"MTN SME"
I still get:
"M S- yam"
for the above reqeust:
"MTN CG"

Sorry you're going to have to debug your code yourself

sighs

it's unfortunate, but the problem seems to be in your code's logic. I can try to take a look. Please show the code for your full function.

wow, I appreciate you @safwan

I discovered the dart file holding all variables on cloud function code was the one caching it. So I had to dispose them and did a check before every request, I appreciate you @Steven @safwan
I was thinking that cloud function doesn't remember any data after execution, that's why my focus was on both ends
Recommended threads
- Function running in cloud but not locall...
Hi everyone, I have an appwrite function which is on python3.12 runtime. I have a library (hnswlib) which builds wheels during installation. This works on appwr...
- Permissions for bulk operation
Hi team, I have a question: “In the databases.createDocuments bulk API, can I set document-level permissions? If yes, how exactly should I include the permissio...
- Limit File Upload count?
Is there a way to limit the number of files a user can upload? I know there's a limit of file size but in my case I'd like to limit the user to only upload x am...
