Back

The Fetch API is an experimental feature.

  • 0
  • Functions
  • Cloud
Irvine
23 Sep, 2023, 10:02

Hi Support

After the cloud beta update to 1.4.3, I also upgrade my function to use the latest Appwrite SDK (9.0.0) and also change to use the context instead of req and res. The console keeps shows up these messages, not sure why this will show out. The function still ends completed, just want to make sure am I doing something wrong causing this message keeps showing up.

TypeScript
----------------------------------------------------------------------------
Unsupported logs detected. Use context.log() or context.error() for logging.
----------------------------------------------------------------------------
(node:22) ExperimentalWarning: The Fetch API is an experimental feature. This feature could change at any time
(Use `node --trace-warnings ...` to show where the warning was created)

----------------------------------------------------------------------------

I have lodash and Appwrite SDK installed for my function, and only have function calls with databases client (databases.getDocument, databases.createDocument, databases.updateDocument, and databases.listDocuments) in my function.

TL;DR
After upgrading to Appwrite SDK 9.0.0 and using the context instead of req and res, you are seeing the message "Unsupported logs detected. Use context.log() or context.error() for logging." and an "ExperimentalWarning" regarding the Fetch API. The message is not causing any issues and can be ignored for now. This is a known issue and has been fixed in Node 18.13.0, but the Cloud version is still using Node 18.0.0. There is no specific solution mentioned in the thread.
darShan
23 Sep, 2023, 10:11

The message is most probably logged internally by node via console.log I guess which the new functions do not suggest. Client side should always use context.log(). You can ignore this for now.

This is fixed on Node: 18.13.0 but the Node used by Cloud is most probably 18.0.0.

darShan
23 Sep, 2023, 10:36

Based on this issue, I've created a feature request - https://github.com/appwrite/appwrite/issues/6314

Irvine
23 Sep, 2023, 12:21

Ok, thanks a lot 😀

VincentGe
23 Sep, 2023, 13:45

Yes, we no longer use console.log for several reasons

  1. reliability was suspect
  2. privacy reasons. Some system libraries log by themselves and the logs may contain sensitive information.
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