infinity warring logs in nextjs project <Third-party cookie will be blocked in future Chrome versions as part of Privacy Sandbox.>
✅ Prerequisites
- [ done] Did you perform a cursory search of open issues? Is this bug already reported elsewhere?
- [ "magic-sdk": "^28.3.0",] Are you running the latest SDK version?
- [yes ] Are you reporting to the correct repository (
magic-sdk)?
🐛 Description
I had nextjs project and I integrate XDC network with magic-sdk everything is working fine but I face infinity warring logs Third-party cookie will be blocked in future Chrome versions as part of Privacy Sandbox. nextjs version 13.4.19 magic-sdk: 28.3.0 when deploy project on ec2 aws it crashed because of infinity warring logs
💻 Code Sample
const { Web3 } = require("web3")
import { Magic } from "magic-sdk"
my function is
try {
const magic = new Magic(process.env.NEXT_PUBLIC_MAGIC_API_KEY || "", {
network: {
rpcUrl: process.env.NEXT_PUBLIC_RPCURL,
chainId: process.env.NEXT_PUBLIC_CHAINID,
}
});
const web3 = await new Web3(magic.rpcProvider)
const accounts = await web3?.eth.getAccounts()
const contract = new web3.eth.Contract(murabhaContractABI.abi, murabhaContractABI.address);
const gasPrice = await web3.eth.getGasPrice();
const tx = await contract.methods.createToken(data.name, data.symbol).send({ from: accounts[0], gasPrice: gasPrice, });;
} catch (error) {
console.error('Error creating tokens', error.message);
}
} catch (error: any) {
/// update error message
}
};
🌎 Environment
| Software | Version(s) |
| nextjs | 13.4.19 |
| magic-sdk | 28.3.0 |
| Browser | chrome and firefox |
| yarn | 1.22.17 |
| Operating System | windows |
We are hitting this as well and it is pretty crazy! Struggling to get magic working with rainbowkit.
@CryptoGraffe Can you state your issue? I'm having pretty same issues, can't seem to get it working, my wagmi.store states keep getting refreshed on page load, using dedicatedWalletConnector approach tho :))