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

uuid library doesn't work well with expo #950

Open
2 of 4 tasks
joonaathaan opened this issue Oct 6, 2024 · 4 comments · May be fixed by #952
Open
2 of 4 tasks

uuid library doesn't work well with expo #950

joonaathaan opened this issue Oct 6, 2024 · 4 comments · May be fixed by #952
Labels

Comments

@joonaathaan
Copy link

joonaathaan commented Oct 6, 2024

Describe the bug

Error: crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported

Reproduction and solution

Use it with any expo app, simply add the [email protected]

Solution

After i found the error originating from the uuid library, i checked the latests commits and i noticed it was added recently so i downgraded to 2.5.6 which solved the issue.
i think this should be helpful to fix the issue.

Additional context

[email protected]
[email protected]

  • iOS
  • Android
  • Web

If you are using expo please indicate here:

  • I am using expo
@joonaathaan joonaathaan added the bug label Oct 6, 2024
@joonaathaan joonaathaan changed the title Bug Report uuid library doesn't work well with expo Oct 6, 2024
@viktordanko
Copy link

+1 using Metro

@OluwaferanmiLove
Copy link

Hello, I'm having this issue too

@BrunoPigat
Copy link

+1 using Metro;
Android;

[email protected]
[email protected]

@Arshiash80
Copy link

I've created a pull request that integrates the react-native-get-random-values polyfill, which should resolve this problem. This addition ensures that the uuid library functions correctly within the React Native environment by providing the necessary crypto functionality.

Here's the link to the PR for easy access: #952

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