Back

How to get user request that was sent to dart function and also import secret values from env var

  • 0
  • Functions
  • Flutter
  • Cloud
dammy
27 Oct, 2023, 03:00
TypeScript
description: A new Flutter project.
environment:
  # sdk: '>=2.18.2 <3.0.0'
  sdk: ">=2.19.6 <3.0.0"

dependencies:
  flutter_svg:
  page_transition:
  flutter_html:
  flutter_widget_from_html:
  flutter_easyloading:
  # webview_flutter:
  # monnify_flutter_sdk_plus:
  # flutter_inappwebview:

  flutter_monnify:
  dio:
  connectivity_plus:
  http:
  get_storage:
  # animated_text_kit:p
  # screenshot:
  # appwrite_auth_kit:
  # dart_appwrite:
  # rflutter_alert:
  # flutter_easyloading:
  cupertino_icons:
  get: #^5.0.0-release-candidate-3
  shared_preferences:
  # awesome_snackbar_content:
  flutter_screenutil:
  url_launcher:
  carousel_slider:
  upgrader:
  # flutter_svg:
  # get_cli:
  # quickalert:
  local_auth:
  pinput:
  # flutter_secure_storage:
  # mailer for otp and notification
  mailer:
  # otp wait
  slide_countdown:
  material_design_icons_flutter:
  ionicons:

  flutter:
    sdk: flutter
  device_preview: ^1.1.0
  device_preview_screenshot: ^1.0.0
  isar: ^3.1.0+1
  isar_flutter_libs: ^3.1.0+1
  appwrite: ^11.0.0

dev_dependencies:
  build_runner: ^2.4.6
  flutter_lints: ^2.0.0
  flutter_test:
    sdk: flutter
  flutter_launcher_icons: ^0.13.1
  flutter_native_splash:
  isar_generator: ^3.1.0+1
TL;DR
The user is experiencing an error after updating their client code. They want to know if they need to update all their cloud functions as well. The response is that they will need to manually update the cloud code if they want to upgrade it. However, functions from before version 1.4 should still work. The user asks how to update the cloud code without doing it manually and getting an error. The response suggests uninstalling the app, reloading the IDE, and running it again. The user then asks for the function signature for creating execution. The response asks for the user to share their pubspec.lock file. The user shares their dependencies
Drake
27 Oct, 2023, 03:00

Look at the version of the appwrite package...

dammy
27 Oct, 2023, 03:01

I just uodated it 3 min ago

Drake
27 Oct, 2023, 03:01

It was 8...

dammy
27 Oct, 2023, 03:01

was thinking version 11 is the problem

dammy
27 Oct, 2023, 03:01

yes it was version 11.0.0 like 10 min ago

Drake
27 Oct, 2023, 03:03

At the command line, run

TypeScript
flutter clean
flutter pub get
Drake
27 Oct, 2023, 03:04

Then share your pubspec.lock file

dammy
27 Oct, 2023, 03:04

I just did that

dammy
27 Oct, 2023, 03:05
Drake
27 Oct, 2023, 03:07

You should be on the right version...what's the function signature for create execution now?

dammy
27 Oct, 2023, 03:07

you mean?

Drake
27 Oct, 2023, 03:08

Uninstall the app, reload your IDE and run it again. Do you still get this error?

dammy
27 Oct, 2023, 03:09

now older function execute code is showing error and asking me to replace data for body

Drake
27 Oct, 2023, 03:09

Obviously...

dammy
27 Oct, 2023, 03:10

so how do I update the corresponding cloud code without doing it mannually and having errror

Drake
27 Oct, 2023, 03:11

If you want to upgrade them, you'll have to do it manually. However, functions from before 1.4 should still work

dammy
27 Oct, 2023, 03:12

but already showing error

Drake
27 Oct, 2023, 03:12

What do you mean?

dammy
27 Oct, 2023, 03:13

former functions that works well before the flutter clean

Drake
27 Oct, 2023, 03:13

Obviously you'll need to update all your client code

dammy
27 Oct, 2023, 03:14

I did, any need to update all cloud functions?

dammy
27 Oct, 2023, 03:14

cause after uodating client code, error persist in older ones

dammy
27 Oct, 2023, 03:23

I must be sincere @Steven you mean alot to mee

I just hope all works, thanks Man

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