-
Notifications
You must be signed in to change notification settings - Fork 60
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
Issues after 3.0.11 update #64
Comments
hi, you can check #60 |
same issue, tried with 3.0.10 and that's broken as well. |
@Incanus3 i managed to get it working by forcing 3.0.9 |
So did I, after I finally found the source of the problem. At least this will force me to use yarn instead of npm. If I had yarn.lock, I could've found it much sooner. |
The update to add this check completely breaks Webpack since it ultimately utilizes this package for crypto. |
shoulf be fixed |
Not fixed. The problem is the core functionality in Webpack depends on this code not throwing an error. When the crypto.pbkdf2Sync value is undefined Webpack was OK with that especially if you did not really need to use the pbkdf2 method. Now what happens is there is an error thrown by the browser because crypto.pbkdf2Sync is actually undefined when using Webpack. Even if that did not error out, when the updated code throws an error, the code still breaks running Webpack bundles. |
@danbrianwhite are you getting an error in version 3.0.12 and if so what is it? |
@calvinmetcalf when crypto is required, it does not have the key pbkdf2Sync. This key is undefined which throws a JS error because the value is undefined. Even if that undefined value is checked for, it will still break Webpack because it expects not to be thrown and the code will now be thrown because of this commit |
what exactly is your config, that file shouldn't even be loaded in the first place because of the browser field in the package.json |
that's what #62 fixed |
@calvinmetcalf Thank you for following up with me. The issue is indeed fixed now with v 3.0.12 - it looks like it took a little time to propagate through my cache. Thank you for fixing the issue. |
@calvinmetcalf seems like you had fun overnight. Anything published/unpublished? |
I believe it's all fine now |
basically I forgot to update browser object so it was pointing at the wrong file |
I have the following section of code in my program, which was working before the update:
var crypto = require('crypto') /* istanbul ignore next */ if (crypto.pbkdf2Sync.toString().indexOf('keylen, digest') === -1) { throw new Error('Unsupported crypto version') }
After updating 3.0.11, pbkdf2Sync is undefined and so my code is failing. Any information on why this may be happening would be greatly appreciated.
The text was updated successfully, but these errors were encountered: