From 3fb4a06b286bbcf020de843ce8e2c74d24195585 Mon Sep 17 00:00:00 2001 From: Marc Jakobi Date: Tue, 11 Jun 2024 19:51:51 +0200 Subject: [PATCH] fix: fail silently if populating the rocks cache fails at startup --- plugin/rocks.lua | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/plugin/rocks.lua b/plugin/rocks.lua index 2d6c6eea..b0799bd0 100644 --- a/plugin/rocks.lua +++ b/plugin/rocks.lua @@ -43,10 +43,12 @@ if not config.lazy then log.trace("Populating caches") nio.run(function() local cache = require("rocks.cache") - nio.gather({ - cache.populate_cached_rocks, - cache.populate_removable_rock_cache, - }) + pcall(function() + nio.gather({ + cache.populate_cached_rocks, + cache.populate_removable_rock_cache, + }) + end) end) end