When installing semgrep version greater then 1.30.0, the process always crashes.
tuhaolam opened this issue · comments
Describe the bug
When installing semgrep version greater then 1.30.0, the process always crashes.
To Reproduce
semgrep --version
Fatal error: exception Unix.Unix_error(Unix.ENOSYS, "getrandom", "")
Raised by primitive operation at Mirage_crypto_rng_unix.getrandom in file "rng/unix/mirage_crypto_rng_unix.ml", line 12, characters 2-39
Called from Mirage_crypto_rng_lwt.getrandom_init in file "rng/lwt/mirage_crypto_rng_lwt.ml", line 36, characters 13-49
Called from Stdlib__List.mapi in file "list.ml", line 96, characters 20-25
Called from Stdlib__List.mapi in file "list.ml", line 96, characters 34-50
Called from Stdlib__List.mapi in file "list.ml", line 96, characters 34-50
Called from Stdlib__List.mapi in file "list.ml", line 96, characters 34-50
Called from Stdlib__List.mapi in file "list.ml" (inlined), line 98, characters 15-25
Called from Mirage_crypto_rng_lwt.initialize in file "rng/lwt/mirage_crypto_rng_lwt.ml", line 58, characters 6-37
Called from Tls_lwt in file "lwt/tls_lwt.ml", line 276, characters 9-76
Expected behavior
No bug.
Screenshots
What is the priority of the bug to you?
- P0: blocking your adoption of Semgrep or workflow
- P1: important to fix or quite annoying
- P2: regular bug that should get fixed
Environment
on cvm
Use case
Can you share more information about the system you're running this on? The error indicates getrandom(2)
isn't supported, and that would be needed to understand why.
@tuhaolam closing as can't reproduce but feel free to re-open with more info
I found that the reason is my host(centos 7.2 final) not support getrandom syscall, as https://stackoverflow.com/questions/30800331/getrandom-syscall-in-c-not-found shows. And this feature supports after v1.34.0.
+1