Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IOS: Missing Plugin Implementation #9

Closed
agalambas opened this issue Sep 16, 2022 · 17 comments
Closed

IOS: Missing Plugin Implementation #9

agalambas opened this issue Sep 16, 2022 · 17 comments
Labels
apple [See issue #68] Just Apple being Apple again... bug Something isn't working hacktoberfest Fixing this issue will get you one PR closer to completing Hacktoberfest :)

Comments

@agalambas
Copy link

agalambas commented Sep 16, 2022

Describe the bug

When I authenticate to my custom backend in the iOS app, I get this error!
Error: MissingPluginException(No implementation found for method authenticate on channel flutter_web_auth_2)

To Reproduce

Steps to reproduce the behavior:

  1. You can run the example given in the package itself

Expected behavior

It should work

Device

Device: iPad Pro 9.7"
OS: iOS 15.0.2
flutter_web_auth_2 version: 1.1.2

Additional context

Maybe I am missing some documentation here but I followed everything in the readme

@ThexXTURBOXx
Copy link
Owner

Hi, could you please try using flutter_web_auth_2 version pinned to exactly 1.1.0 and report back if that worked? :)

@agalambas
Copy link
Author

Just tested it and It behaves the same

@ThexXTURBOXx
Copy link
Owner

Okay, crazy idea: Could you try with version exactly 1.0.0 as well?
Because if that one also does not work, there seems to be something fundamentally wrong somewhere since I got confirmation about that one working in the past: #1 (comment)

@agalambas
Copy link
Author

Its giving me the same error, so is it probably some setup that I'm doing wrong?

@ThexXTURBOXx
Copy link
Owner

It seems like something goes wrong on your side, yes.
Sadly, I have neither a developer account nor any device by Apple. So, I am not able to test anything there myself properly.

@AndreiRoze, you had tested this package successfully before. Was there something special you needed to do or did it just work out of the box?
Also, did you notice anything that broke in the mean time?

@ThexXTURBOXx ThexXTURBOXx added the bug Something isn't working label Sep 17, 2022
@AndreiRoze
Copy link

Library works correct, i can recheck it again on monday. For fix that issue try to:

  1. flutter clean
  2. delete pubspec.lock file (NOT pubspec.yaml)
  3. flutter pub get
  4. flutter run

If it's doesnt help, could you provide file ios -> Runner -> AppDelegate.swift from your project?

@ThexXTURBOXx
Copy link
Owner

Thanks for confirming! :)

@agalambas
Copy link
Author

I have no idea what was the solution but it is now working in the version 1.0.0, didn't test the latest version yet

@Jenry94
Copy link

Jenry94 commented Sep 19, 2022

i have the same issue :c dont work in ios

@ThexXTURBOXx ThexXTURBOXx reopened this Sep 19, 2022
@ThexXTURBOXx
Copy link
Owner

Does 1.0.0 work for you? @Jenry94

@Jenry94
Copy link

Jenry94 commented Sep 19, 2022

don't work for me in any version, i cleaned , update pods, delete and add the plugin and dont work. Only in IOS.

@ThexXTURBOXx
Copy link
Owner

As already said, alas I cannot test on iOS myself. That's why I rely on fixes by other people in that regard.
If someone finds a bug or something else, please propose a PR and I will include it in the next release :)

@AndreiRoze
Copy link

AndreiRoze commented Sep 20, 2022

I recheck app from example with latest version of library, it's work correct. I use iPad with iOS 15.7(latest)

IMG_0015

If you can, please provide minimal reproducible code sample which doesn't work.
Also try some fixes from flutter/flutter#10912 may be it will help you.

@ThexXTURBOXx
Copy link
Owner

@AndreiRoze Thank you very much for re-confirming this! I am sorry for letting you do all this work 😅
To everyone having a similar issue, please check the generated files if they are correct (according to the issue @AndreiRoze linked above).
If nothing helps, try flutter clean and then flutter build <platform> again (be sure to replace <platform> with the specific platform you want to target, e.g. ios).
I will close this issue as completed as soon as I mention this in the documentation.

@ThexXTURBOXx ThexXTURBOXx added the hacktoberfest Fixing this issue will get you one PR closer to completing Hacktoberfest :) label Sep 26, 2022
@ThexXTURBOXx
Copy link
Owner

I tagged this PR as being part of Hacktoberfest.
So, if someone is able to fix and properly test this issue, he is one step closer to completing Hacktoberfest 2022 :)

@ThexXTURBOXx ThexXTURBOXx added the apple [See issue #68] Just Apple being Apple again... label Oct 24, 2022
@rafalbednarczuk
Copy link

rafalbednarczuk commented Nov 24, 2022

I managed to find one reproducible case on iOS.
It throws the exceptions if the url is invalid, for example having whitespace characters inside url host/port.
Steps to reproduce:

  1. clone project and open example/main.dart
  2. Add (whitespace) after : in the url.
    const url = 'http://127.0.0.1: 43823/';
  1. Run app.
    It throws MissingPluginException which is quite confusing.

On Android, the same case causes to open a blank Android Custom Tab as expected and doesn't throw exception until closing Android Custom Tab which is also as expected.

@ThexXTURBOXx
Copy link
Owner

@rafalbednarczuk Thank you very much for the information!
Since I do not want to assert the correctness of URLs passed into the library (they are just too versatile), I think, I will let this be handled by Apple (in their bad bad way).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
apple [See issue #68] Just Apple being Apple again... bug Something isn't working hacktoberfest Fixing this issue will get you one PR closer to completing Hacktoberfest :)
Projects
None yet
Development

No branches or pull requests

5 participants