From 8d7fa04c29f6213e8c6a5f904f1376b9d96b510d Mon Sep 17 00:00:00 2001 From: Lukasz Samson Date: Sun, 24 Dec 2023 23:31:39 +0100 Subject: [PATCH] crash the server if crypto app is not installed --- apps/language_server/lib/language_server.ex | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/apps/language_server/lib/language_server.ex b/apps/language_server/lib/language_server.ex index baf3b5d71..93f6bd00c 100644 --- a/apps/language_server/lib/language_server.ex +++ b/apps/language_server/lib/language_server.ex @@ -191,9 +191,10 @@ defmodule ElixirLS.LanguageServer do def check_otp_install_complete do try do :io_lib.format(~c"~p", [[1]]) + :crypto.strong_rand_bytes(1) :ok rescue - e in ErlangError -> + e in [ErlangError, UndefinedFunctionError] -> Logger.error(Exception.message(e)) message = incomplete_installation_message()