BuildID: 3825
Status: FAIL
Image: melezhik/sparrow:alpine_arm
Worker status: OK
---
Date: 26.11.2023 @ 14:27
Time elapsed: 87 sec
---
SCM:
https://github.com/melezhik/Raku-Net-Whois.git
Git sha: 135d5dd
Git comment: run code examples
tasks:
-
name: zef-build
language: Bash
default: true
code: |
set -e
cd source/
zef install .
followup:
-
name: code_examples
-
name: code_examples
language: Raku
followup:
-
name: test_report
init: |
"{cache_root_dir()}/command.raku".IO.spurt(config()<code>);
run_task "example", %(
command => "{cache_root_dir()}/command.raku",
cnt => config()<cnt>,
);
subtasks:
-
name: example
language: Bash
code: |
echo "############################################# test_${cnt} ################################################"
echo "run: ["
cat $command
echo "]"
raku $command
code: |
say "Finished";
if "{cache_root_dir()}/tests/{config()<cnt>}.ok".IO ~~ :e {
say ">>> PASSED";
update_state(%( test => config()<cnt>, result => "PASSED" ))
} else {
say ">>> FAILED";
update_state(%( test => config()<cnt>, result => "FAILED" ))
}
hub:
language: Raku
code: |
my $code;
my @examples;
my $fh = open("source/README.md");
my $cnt = 1;
for $fh.lines -> $i {
if $i ~~ /^ "```raku"/ ^fff^ $i ~~ /^ "```"/ {
$code ~= "$i\n"
} elsif ($i ~~ /^ "```raku"/ or $fh.eof) {
@examples.push(%( config => %( code => $code, cnt => $cnt++ ) )) if $code;
$code = "";
}
}
$fh.close();
update_state(%( list => @examples ));
-
name: test_report
language: Raku
code: |
for config()<parent><state><> -> $i {
say "test_{$i<test>} >>> {$i<result>}";
}
[35m14:26:37[0m :: [repository] - index updated from https://sparrowhub.io/repo/api/v1/index
run stage: run
source directory does not yet exist, download source archive from storage
[35m14:26:40[0m :: [repository] - installing pack-unpack, version 0.000001
[1;36m[task run: task.bash - unpack source archive][0m
[1;36m[dump code: task.bash][0m
[1] set -e
[2]
[3] file=$(config file)
[4] dir=$(config dir)
[5]
[6] echo "tar -xzf $file "
[7]
[8] tar -xzf $file
[9]
[10] if test $dir; then
[11] ls -l $dir
[12] fi
[13]
[14]
[1;36m[task stdout][0m
[35m14:26:42[0m :: tar -xzf source.tar.gz
[1;36m[task run: task.bash - tasks/zef-build][0m
[1;36m[dump code: task.bash][0m
[1] set -e
[2] cd source/
[3] zef install .
[4]
[1;36m[task stdout][0m
[35m14:26:44[0m :: ===> Staging Net::Whois:ver<0.0.2>:auth<zef:FRITH>
[35m14:26:49[0m :: ===> Staging [OK] for Net::Whois:ver<0.0.2>:auth<zef:FRITH>
[35m14:26:49[0m :: ===> Testing: Net::Whois:ver<0.0.2>:auth<zef:FRITH>
[35m14:26:49[0m :: ===> Testing [OK] for Net::Whois:ver<0.0.2>:auth<zef:FRITH>
[35m14:26:49[0m :: ===> Installing: Net::Whois:ver<0.0.2>:auth<zef:FRITH>
some followup jobs failed or timeouted: ${:FAIL(1), :OK(0), :TIMEOUT(0)}
The spawned command 'docker exec -i sparrow-worker sh -l /var/.sparrowdo/env/zef-build/.sparrowdo/sparrowrun.sh' exited unsuccessfully (exit code: 1, signal: 0)
in block <unit> at /home/ubuntu/projects/rakudo/rakudo-2022.12/install/share/perl6/site/resources/7E8029CBEC6AEAB4CF3B86B0FA3D5E6E21936B90 line 13
in sub MAIN at /home/ubuntu/projects/rakudo/rakudo-2022.12/install/share/perl6/site/bin/sparrowdo line 3
in block <unit> at /home/ubuntu/projects/rakudo/rakudo-2022.12/install/share/perl6/site/bin/sparrowdo line 1
[35m14:27:03[0m :: [repository] - index updated from https://sparrowhub.io/repo/api/v1/index
run stage: run
[1;36m[task run: task.raku - tasks/code_examples-hub][0m
[1;36m[dump code: task.raku][0m
[1] my $code;
[2] my @examples;
[3] my $fh = open("source/README.md");
[4] my $cnt = 1;
[5] for $fh.lines -> $i {
[6] if $i ~~ /^ "```raku"/ ^fff^ $i ~~ /^ "```"/ {
[7] $code ~= "$i\n"
[8] } elsif ($i ~~ /^ "```raku"/ or $fh.eof) {
[9] @examples.push(%( config => %( code => $code, cnt => $cnt++ ) )) if $code;
[10] $code = "";
[11] }
[12] }
[13] $fh.close();
[14] update_state(%( list => @examples ));
[15]
[1;36m[task stdout][0m
[1;36m[task run: task.bash - tasks/code_examples][0m
[1;36m[dump code: task.bash][0m
[1] echo "############################################# test_${cnt} ################################################"
[2] echo "run: ["
[3] cat $command
[4] echo "]"
[5] raku $command
[6]
[1;36m[task stdout][0m
[35m14:27:09[0m :: ############################################# test_1 ################################################
[35m14:27:09[0m :: run: [
[35m14:27:09[0m :: use Net::Whois;
[35m14:27:09[0m ::
[35m14:27:09[0m :: my Net::Whois $w .= new;
[35m14:27:09[0m :: my %h = $w.query: $who, $using;
[35m14:27:09[0m :: for %h.kv -> $k, $v { say "$k => $v[*]" }
[35m14:27:09[0m :: ]
[1;36m[task stderr][0m
[35m14:27:09[0m :: [31m===[0mSORRY![31m===[0m Error while compiling /home/worker/.sparrow6/tmp/1463/command.raku
[35m14:27:09[0m :: Variable '$who' is not declared. Did you mean '&WHO'?
[35m14:27:09[0m :: at /home/worker/.sparrow6/tmp/1463/command.raku:4
[35m14:27:09[0m :: ------> [32mmy %h = $w.query: [33m⏏[31m$who, $using;[0m
[35m14:27:09[0m :: task exit status: 1
[35m14:27:09[0m :: task tasks/code_examples FAILED
The spawned command 'docker exec -i sparrow-worker sh -l /var/.sparrowdo/env/code_examples/.sparrowdo/sparrowrun.sh' exited unsuccessfully (exit code: 1, signal: 0)
in block <unit> at /home/ubuntu/projects/rakudo/rakudo-2022.12/install/share/perl6/site/resources/7E8029CBEC6AEAB4CF3B86B0FA3D5E6E21936B90 line 13
in sub MAIN at /home/ubuntu/projects/rakudo/rakudo-2022.12/install/share/perl6/site/bin/sparrowdo line 3
in block <unit> at /home/ubuntu/projects/rakudo/rakudo-2022.12/install/share/perl6/site/bin/sparrowdo line 1