Strange error as a result of missing repositories
We need some nicer output for this, at least. This happened when there was a mistake in the URI for the repository index.
DIE:src/pkgupdate/main.c:65 (main):an error object {
errors: table: 0x2b0cb0,
msg: Multiple exceptions (6),
tp: error,
reason: multiple
}
Stack Traceback
===============
(2) C function 'function: 0x2b97b0'
(3) upvalue C function 'error'
(4) Lua global 'get_repos' at line 137 of chunk '"postprocess"]'
Local variables:
uris = nil
extract_events = table: 0x2b0c80 {1:userdata: 0x322278, 2:userdata: 0x35af28, 3:userdata: 0x2d3c28, 4:userdat
+a: 0x305408 (more...)}
errors = table: 0x2b0cb0 {1:curl: (22) The requested URL returned error: 404 Not Found
, 2:curl: (22) The requested URL returned error: 404 Not Found
(more...)}
fatal = boolean: true
multi = Multiple exceptions (6) {errors:table: 0x2b0cb0, msg:Multiple exceptions (6), tp:error, reason:multip
+le (more...)}
(5) Lua field 'run' at line 250 of chunk '"postprocess"]'
(6) Lua function '?' at line 52 of chunk '"updater"]'
Local variables:
entrypoint = string: "file:///etc/updater/entry.lua"
tlc = table: 0x2bb9c0 {env:table: 0x2bd6a0, level_check:function: 0x2bd6d0, tp:context, sec_level:Full (more.
+..)}
ep_uri = table: 0x2bda20 {ok:function: 0x2bdd40, tp:uri, cback:function: 0x2bde90, callbacks:table: 0x2be680
+(more...)}
ok = boolean: true
tls = string: "-- Do not edit this file. It is the entry point. Edit the user.lua file.\
\
local uci_ok, uci = pcall(require, \"uci\")\
local disable_all = false\
local branch\
local lists\
if uci_ok then\
local cursor = uci.cursor()\
local disable = cursor:get(\"updater\", \"override\", \"disable\")\
if disable == \"true\" then\
-- The user doesn't want the updater to run\
error(\"Updater disabled\") -- TODO: Something less brutal?\
end\
branch = cursor:get(\"updater\", \"override\", \"branch\")\
if branch then\
branch = \"-\" .. branch\
end\
lists = cursor:get(\"updater\", \"pkglists\", \"lists\")\
else\
ERROR(\"UCI library is not available. Not processing user lists.\")\
end\
branch = branch or \"\"\
\
-- Guess what board this is.\
local f = io.open(\"/tmp/sysinfo/model\")\
local base_model\
if f then\
local raw_model = f:read()\
if raw_model then\
if raw_model:match(\"[Oo]mnia\") then\
base_model = \"omnia\"\
elseif raw_model:match(\"[Tt]urris\") then\
base_model = \"turris\"\
end\
end\
f:close()\
end\
\
if base_model then\
-- The distribution script. It contains the repository and bunch of basic packages. The URI is computed based o
+n the branch and the guessed board\
Script(\"turris\", \"https://api.turris.cz/updater-defs/\" .. base_model .. branch .. \".lua\", { security = \"
+Remote\", verification = \"cert\", ca = \"file:///etc/ssl/updater.pem\", crl = \"file:///tmp/crl.pem\" })\
else\
WARN(\"Failed to guess the board, relying on user-provided scripts\")\
end\
\
-- Some provided by the user\
Script \"user-src\" \"file:///etc/updater/user.lua\" { security = \"Local\" }\
-- Some auto-generated by command line\
Script \"auto-src\" \"file:///etc/updater/auto.lua\" { security = \"Local\" }\
-- Go through user lists and pull them in. Note that this is a temporary solution\
-- with hardcoded URIs\
if uci_ok then\
if type(lists) == \"string\" then\
lists = {lists}\
end\
if type(lists) == \"table\" then\
for _, l in ipairs(lists) do\
-- TODO: Make signatures work\
-- TODO: Make restricted security work\
Script(\"userlist-\" .. l, \"https://api.turris.cz/updater-defs/\" .. l .. \".lua\", { security
+= \"Remote\", verification = \"cert\", ca = \"file:///etc/ssl/updater.pem\", crl = \"file:///tmp/crl.pem\" })\
end\
end\
end\
"
err = nil
Aborted