URGENT: Could not get result from torus nodes \n Unable to resolve enough promises

Hello!

My login flow was working fine but since a few hours I am getting the following errors when trying to login with a new session. We are about to go live with our alpha version and would appreciate swift assistant in this matter.

Errors:
Cross-Origin Request Blocked
&
Error: Could not get result from torus nodes Unable to resolve enough promises.

  • SDK Version: “@web3auth/base”: “^7.3.2”
  • Platform: Next.js

The following is happening on auth.web3auth.io/v6/callback during the redirect:

Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://node-1.dev-node.web3auth.io/sss/jrpc. (Reason: CORS header ‘Access-Control-Allow-Origin’ missing). Status code: 502

(this was not happening before)

Login code snippet:


  useEffect(() => {
    const initWeb3Auth = async () => {
      try {
        const chainConfig = {
          chainNamespace: CHAIN_NAMESPACES.EIP155,
          chainId: '0x1',
          rpcTarget: 'https://rpc.ankr.com/eth',
          displayName: 'Ethereum Mainnet',
          blockExplorer: 'https://etherscan.io/',
          ticker: 'ETH',
          tickerName: 'Ethereum',
        };

        const web3auth = new Web3AuthNoModal({
          clientId,
          chainConfig,
          web3AuthNetwork: 'sapphire_devnet',
        });

        const privateKeyProvider = new EthereumPrivateKeyProvider({
          config: { chainConfig },
        });

        const openloginAdapter = new OpenloginAdapter({
          adapterSettings: {
            clientId,
            network: 'testnet',
            uxMode: 'redirect',
          },
          privateKeyProvider,
        });

        web3auth.configureAdapter(openloginAdapter);

        await web3auth.init();

        setWeb3auth(web3auth);
        setProvider(web3auth.provider);

        const userInfo = await web3auth.getUserInfo();
        if (!userInfo) {
          console.error('Failed to get user info');
          return;
        }

        const app_scoped_privkey = await web3auth.provider?.request({
          method: 'eth_private_key',
        });
        if (!app_scoped_privkey) {
          console.error('Failed to get app scoped private key');
          return;
        }

        const appPubKey = getPublicCompressed(
          Buffer.from(String(app_scoped_privkey).padStart(64, '0'), 'hex')
        ).toString('hex');

        setAppPubKey(appPubKey);
        setUserIDToken(userInfo.idToken);

        if (appPubKey && userInfo.idToken) {
          setVerifyingSession(true);
          verifyUserAndLogin(appPubKey, userInfo.idToken);
        }
      } catch (error) {
        console.error(error);
      }
    };

    initWeb3Auth();
    checkSession();
  }, []);

  const login = useCallback(async () => {
    try {
      const web3authProvider = await web3auth.connectTo(
        WALLET_ADAPTERS.OPENLOGIN,
        { loginProvider: 'discord' }
      );
      setProvider(web3authProvider);
    } catch (error) {
      console.error('Login error:', error);
    }
  }, [web3auth]);

hi @aaron1

I am aware of your issue and I will consult with the team urgently.

I’ll come back as soon as I have some news.

hi @aaron1
Can you share with me your user region, verifier, verifierId details, and the response from the failing requests.

Thanks

Hi @TomTom

Thanks for your help on this. I am currently connecting through your “Web3Auth Sapphire Devnet” Discord app, not through a custom authentication verifier.

image

This is the post request that fails:

image

All of this is happening on this domain in the redirect flow

image

All of this was not happening before today or even before the last few hours. I could definitely still successfully complete the login flow yesterday and I didn’t touch the logic on my end since then. Please check what might cause this issue!

I also confirm same problem. I didn’t touch mo auth logic.

same here. issue started today.

Thanks for reporting this issue. This looks like some error in our CORS policy. Our dev team is looking into this issue on priority and will be fixing it as soon as possible. We’ll give you an update in a few hours.

We apologize for the inconvenience caused by the Devnet disruption in the European region due to testing a new feature. We expect to resolve the issue within 1-2 hours. In the meantime, please utilize the Mainnet or connect via VPN to Devnet servers in the Asia or USA regions for testing.

Thank you for your understanding.

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.