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

Can't initialize after update to 6.0.1 #95

Open
mhsnprvr opened this issue Dec 6, 2024 · 5 comments
Open

Can't initialize after update to 6.0.1 #95

mhsnprvr opened this issue Dec 6, 2024 · 5 comments

Comments

@mhsnprvr
Copy link

mhsnprvr commented Dec 6, 2024

the code is exactly like example, and what I was using for version 5
I get this error:

error initializing app PlatformException(error, java.util.concurrent.ExecutionException: java.lang.Exception: No user found, please login again!, java.util.concurrent.ExecutionException: java.lang.Exception: No user found, please login again!, null)

    await Web3AuthFlutter.init(
      Web3AuthOptions(
        clientId:Env.web3AuthClientId,
        sessionTime: 60 * 60 * 24 * 7,
        network: Network.sapphire_mainnet,
        redirectUrl: resolveRedirectUrl(),
        whiteLabel: WhiteLabelData(
          appName:'Podium'
          mode: ThemeModes.dark,
        ),
      ),
    );
    await Web3AuthFlutter.initialize();
    ```
@AyushBherwani1998
Copy link
Member

@mhsnprvr this is expected change in behaviour, we will be releasing a new version soon and migration guide. You should use the Web3AuthFlutter.initialize inside try and catch block.

@mhsnprvr
Copy link
Author

@mhsnprvr this is expected change in behaviour, we will be releasing a new version soon and migration guide. You should use the Web3AuthFlutter.initialize inside try and catch block.

thanks, will wait for docs to be updated
this remains on 6.1.0 also
and I can't get a response from login on 6.1.0

@AyushBherwani1998
Copy link
Member

@mhsnprvr can you share your Android Manifest file, and the redirect URL you use?

@mhsnprvr
Copy link
Author

@mhsnprvr can you share your Android Manifest file, and the redirect URL you use?

            <data android:scheme="podium" android:host="com.web3podium" android:path="/web3auth" />

@mhsnprvr
Copy link
Author

@mhsnprvr can you share your Android Manifest file, and the redirect URL you use?

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"

<application
    tools:replace="android:fullBackupContent,android:label,android:allowBackup"
    android:label="podium"
    android:name="${applicationName}"
    android:enableOnBackInvokedCallback="true"
    android:fullBackupContent="false"
    android:allowBackup="true"
    android:icon="@mipmap/ic_launcher">

    <service
        android:name="com.foregroundservice.ForegroundService"
        android:foregroundServiceType="mediaProjection">
    </service>

    <activity
        android:name=".MainActivity"
        android:exported="true"
        android:launchMode="singleTop"
        android:taskAffinity=""
        android:theme="@style/LaunchTheme"
        android:configChanges="orientation|keyboardHidden|keyboard|screenSize|smallestScreenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
        android:hardwareAccelerated="true"
        android:supportsPictureInPicture="false"
        android:windowSoftInputMode="adjustResize">
        <meta-data android:name="flutter_deeplinking_enabled" android:value="true" />

        <intent-filter android:autoVerify="true">
            <action android:name="android.intent.action.VIEW" />
            <category android:name="android.intent.category.DEFAULT" />
            <category android:name="android.intent.category.BROWSABLE" />
            <data android:scheme="podium" android:host="group-detail" />
            <data android:scheme="podium" android:host="com.web3podium" android:path="/web3auth" />
            <data android:scheme="podium" android:host="referral" />
            <data android:scheme="http" android:host="web3podium.page.link" />
            <data android:scheme="http" android:host="web3podium.page.link/group-detail" />
            <data android:scheme="http" android:host="web3podium.page.link/referral" />
        </intent-filter>

        <!-- Specifies an Android theme to apply to this Activity as soon as
            the Android process has started. This theme is visible to the user
            while the Flutter UI initializes. After that, this theme continues
            to determine the Window background behind the Flutter UI. -->
        <meta-data
            android:name="io.flutter.embedding.android.NormalTheme"
            android:resource="@style/NormalTheme"
        />
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>
    <!-- Don't delete the meta-data below.
         This is used by the Flutter tool to generate GeneratedPluginRegistrant.java -->
    <meta-data
        android:name="flutterEmbedding"
        android:value="2" />
</application>

<queries>
    <package android:name="io.metamask" />
    <package android:name="com.wallet.crypto.trustapp" />
    <package android:name="io.gnosis.safe" />
    <package android:name="me.rainbow" />
    <package android:name="org.toshi" />
    <!-- Add other wallet schemes names here -->
</queries>


<!-- Required to query activities that can process text, see:
     https://developer.android.com/training/package-visibility and
     https://developer.android.com/reference/android/content/Intent#ACTION_PROCESS_TEXT.

     In particular, this is used by the Flutter engine in io.flutter.plugin.text.ProcessTextPlugin. -->
<queries>
    <intent>
        <action android:name="android.intent.action.PROCESS_TEXT" />
        <data android:mimeType="text/plain" />
    </intent>
</queries>
<!-- to use calendar -->
<queries>
    <intent>
        <action android:name="android.intent.action.INSERT" />
        <data android:mimeType="vnd.android.cursor.item/event" />
    </intent>
</queries>
<uses-permission android:name="android.permission.WRITE_CALENDAR" />
<uses-permission android:name="android.permission.READ_CALENDAR" />
<!-- end-  to use calendar -->

<!-- to connect to internet -->
<uses-permission android:name="android.permission.INTERNET" />
<!-- to read images from gallry -->
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
<!-- to access mic -->
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.RECORD_AUDIO" />
<!-- to access notification -->
<uses-permission android:name="android.permission.POST_NOTIFICATIONS" />

<!-- to remove warning in google play -->
<uses-permission android:name="com.google.android.gms.permission.AD_ID" tools:node="remove" />

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants