-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Fix WARNING: Missing strong random number source #309
Comments
What do you mean by "the updated build process"? |
From what I can tell, using ESM modules on tsup triggered a "browser" version of the ethersproject When running locally, if you look at the |
At These are just my inference, I can roll back to that state and see for sure, but with this PR the warning goes away and another ethers project dependency is removed. |
I was just curious if you meant the changes on #238.
To be clear, I believe When I was agreeing with the "getting rid of Ethers" discussion, I was meaning the parts that aren't suitable for us, which are just '@ethersproject/abi' and '@ethersproject/logger' if I'm not missing anything. |
Thank you for the context - yes I think the
This internal one from
I don't feel the need to replace all references to |
Alternatively this can be attacked on a different PR looking into tweaking build process, but I'd be worried about breaking things for the browser instead. |
Just to recap: Could we try doing something like setting the default to be CJS and the browser to default to ESM? |
Yes - correct. I will try another route on a separate branch aimed at adjusting the build configs for better Node compatibility. |
This looks to have been introduced with the updated build process, as the dist files generated by wallet are optimized for the browser explicitly.
The best fix would be to use the internal universal crypto -> random bytes: https://github.com/FuelLabs/fuels-ts/blob/master/packages/keystore/src/universal-crypto.ts
The text was updated successfully, but these errors were encountered: