setup-v
setup-v copied to clipboard
The action starts to fail to setup stable version with `error: unknown function: help.print_and_exit`
it was running nicely till today CI start to fail to install v, here are the logs
Run vlang/setup-v@v1
Resolved as
Downloading vlang ...
Determining the default branch
Retrieving the default branch name
Default branch 'master'
Creating directory: /home/runner/work/vgrid/vgrid/vlang/vlang_linux_x64
Downloading the archive
Downloaded archive 'https://codeload.github.com/vlang/v/legacy.tar.gz/refs/heads/master'
Writing archive to disk
Extracting the archive
/usr/bin/tar xz --warning=no-unknown-keyword --overwrite -C /home/runner/work/vgrid/vgrid/vlang/vlang_linux_x64/282aca22-2b51-4431-85ad-c768b[27](https://github.com/threefoldtech/vgrid/runs/7091283045?check_suite_focus=true#step:3:28)baf4c -f /home/runner/work/vgrid/vgrid/vlang/vlang_linux_x64/[28](https://github.com/threefoldtech/vgrid/runs/7091283045?check_suite_focus=true#step:3:29)2aca22-2b51-44[31](https://github.com/threefoldtech/vgrid/runs/7091283045?check_suite_focus=true#step:3:32)-85ad-c768b27baf4c.tar.gz
Resolved version vlang-v-64b8284
Running make...
cmd/v/v.v:149:15: error: unknown function: help.print_and_exit
147 | fn invoke_help_and_exit(remaining []string) {
148 | match remaining.len {
149 | 0, 1 { help.print_and_exit('default') }
| ~~~~~~~~~~~~~~~~~~~~~~~~~
150 | 2 { help.print_and_exit(remaining[1]) }
151 | else {}
cmd/v/v.v:150:12: error: unknown function: help.print_and_exit
148 | match remaining.len {
149 | 0, 1 { help.print_and_exit('default') }
150 | 2 { help.print_and_exit(remaining[1]) }
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
151 | else {}
152 | }
make: *** [GNUmakefile:97: all] Error 1
Error: Command failed: make
cmd/v/v.v:149:15: error: unknown function: help.print_and_exit
147 | fn invoke_help_and_exit(remaining []string) {
148 | match remaining.len {
149 | 0, 1 { help.print_and_exit('default') }
| ~~~~~~~~~~~~~~~~~~~~~~~~~
150 | 2 { help.print_and_exit(remaining[1]) }
151 | else {}
cmd/v/v.v:150:12: error: unknown function: help.print_and_exit
148 | match remaining.len {
149 | 0, 1 { help.print_and_exit('default') }
150 | 2 { help.print_and_exit(remaining[1]) }
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
151 | else {}
152 | }
make: *** [GNUmakefile:97: all] Error 1
my workflow file wasn't changed recently, I'm using the action with the below configuration:
- name: Set up V version latest
uses: vlang/setup-v@v1
with:
stable: true
Can confirm that this is an issue
Any updates?
@ulises-jeremias can you have a look please?
Working on this right now. I'll send an update soon!
@sameh-farouk as it is mentioned in the README. It is needed to use check-latest: true when using the stable property.
# Set this option if you want the action to use the stable version of V.
# Will be ignored if `check-latest` is false.
stable: false
can you try with this instead?
- name: Set up V version latest
uses: vlang/setup-v@v1
with:
check-latest: true
stable: true
if the issue persists, I'll take a look again
what is mentioned in the docs is that stable will be ignored if I use both check-latest and stable. I should be able to use the stable release in my pipeline, and this is what needs to be fixed.
Hi, @ulises-jeremias @sameh-farouk
I was getting the same error, but by running vlang/setup-v@v1 before actions/checkout as in the linked commit, it stopped failing.
https://github.com/zztkm/microcms-v-sdk/commit/70b48dedcb41acbc7b51b53e56ce43d4d86d0a70
I hope this helps.
The error does not seem to be specific to setup-v, I got the same error on a Windows runner using shell commands, not setup-v . Fixed by moving V build to start of job as suggested by @zztkm. The preceding step that seemed to trigger the error was:
- uses: msys2/setup-msys2@v2
with:
msystem: MINGW64
update: true
install: mingw-w64-x86_64-pcre2
Related to what I'm noticing here: https://github.com/ArtemkaKun/v-project-basement/pull/1#issuecomment-1519070727
Can run without adding a version. As soon as I add a version it runs into a make error.
Edit: Sample workflows: Version included: https://github.com/tobealive/bartender/actions/runs/4778689241/jobs/8495274271#step:3:23 Version removed: https://github.com/tobealive/bartender/actions/runs/4778703542/jobs/8495301795