1

I'm facing an issue after updating all my libraries to comply with AndroidX. Specifically, when I try to use the package "cloud_functions", I receive this error message:

flutter: throwing generic exception
flutter: Exception: Unable to call function funName

Now, I didn't touch the code handling the call, I simply updated the packages in the yaml file.

My code is:

cfResponse = await CloudFunctions.instance.call(
      functionName: 'funName',
      parameters: {
        "p1": p1,
        "p2": p2,
      },
    ).then((response) {
      return response;
    }).catchError((error) {
      print(error);
      return null;
    });

I'm having the same issue both on Android and iOS.

My libraries are at version:
- cloud_functions: ^0.1.1
- firebase_auth: ^0.8.1+4

I'm on Flutter 1.2.1 and Dart 2.1.2

1
  • Hey, AndroidX compatibility can bring up quite some problems with your packages. One way to by-pass the feature is to avoid it alltogether and to use the latest release of each package before AndroidX. More info on that is here. Of course it's not a solution with the future in mind, but it might help you for now. Commented Mar 1, 2019 at 19:07

1 Answer 1

2

I ran into the same issue but only on iOS and came across cloud_functions bug. I manually set the region like the PR does and was able to get it to work. It looks like the fix will be in a coming release.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.