From 40c9fb70afd70fc5d557d61d8764b570b805ff2b Mon Sep 17 00:00:00 2001 From: vados-dev <192440777+vados-dev@users.noreply.github.com> Date: Mon, 4 May 2026 12:20:04 +0300 Subject: [PATCH] Autocommit in repo: ros.vados.ru, generated by owner: root, in 12:20:03 04.05.2026. --- html/AM-GlobalFunc.rsc | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/html/AM-GlobalFunc.rsc b/html/AM-GlobalFunc.rsc index c00d11eda..944197961 100644 --- a/html/AM-GlobalFunc.rsc +++ b/html/AM-GlobalFunc.rsc @@ -17,9 +17,9 @@ :global GlobalFuncReady false; # Git commit id & info, expected configuration version -:global CommitId "main/553/53721779"; +:global CommitId "main/554/f4442323"; :global CommitTAG "unknown"; -:global CommitInfo "Autocommit in repo: ros.vados.ru, generated by owner: root, in 12:05:03 04.05.2026."; +:global CommitInfo "Autocommit in repo: ros.vados.ru, generated by owner: root, in 12:20:03 04.05.2026."; # The variables are received right here. :global GlobalConfVersion 140; @@ -1363,21 +1363,23 @@ } :local FileName ($DirName . "/" . [ $CleanName $0 ] . "-" . [ $GetRandom20CharAlNum ]); - :do { - /tool/fetch check-certificate=$CheckCert url=$fetchUrl dst-path=$FileName \ + :onerror Err { + /tool/fetch check-certificate=$CheckCert $fetchUrl dst-path=$FileName \ http-header-field=({ [ $FetchUserAgentStr $ScriptName ] }) as-value; - } on-error={ + } do={ :if ([ $WaitForFile $FileName 500ms ] = true) do={ $RmFile $FileName; } - $LogPrint debug $0 ("Failed downloading from " . $fetchUrl . " - " . $Err); + :log error ($0 . " Failed downloading from " . $fetchUrl . " - " . $Err); $RmDir $DirName; :return false; } + :if ([ $WaitForFile $FileName 5s ] = false) do={ - $LogPrint debug $0 ("The file downloaded from " . $fetchUrl . " did not show up."); + :log error ($0 . "The file downloaded from " . $fetchUrl . " did not show up."); :return false; } + :local FileSize [ /file/get $FileName size ]; :local Return ""; :local VarSize 0; @@ -1389,7 +1391,7 @@ :delay 100ms; } } - $RmFile $FileName; +# $RmFile $FileName; $RmDir $DirName; :return $Return; } -- 2.52.0