-
Notifications
You must be signed in to change notification settings - Fork 2.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Export and clean up net downloading script #5563
Conversation
adbd3e4
to
d2933b1
Compare
This PR is a part of #5543 and submitted independently thanks to Disservin's advice. 20 fishtest workers ran tasks successfully: |
Can you check if this patch fixes the CI issues, and just include it here? diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml
index 8d209a4f..1e1a1280 100644
--- a/.github/workflows/tests.yml
+++ b/.github/workflows/tests.yml
@@ -342,8 +342,8 @@ jobs:
- name: Test riscv64 build
if: matrix.config.run_riscv64_tests
run: |
- echo "export LDFLAGS='-static' && make clean && make -j4 ARCH=riscv64 build" > script.sh
- docker run --rm --platform ${{ matrix.config.platform }} -v ${{ github.workspace }}/src:/app sf_builder
+ echo "cd src && export LDFLAGS='-static' && make clean && make -j4 ARCH=riscv64 build" > script.sh
+ docker run --rm --platform ${{ matrix.config.platform }} -v ${{ github.workspace }}:/app sf_builder
../tests/signature.sh $benchref
# ppc64 tests
@@ -351,8 +351,8 @@ jobs:
- name: Test ppc64 build
if: matrix.config.run_ppc64_tests
run: |
- echo "export LDFLAGS='-static' && make clean && make -j4 ARCH=ppc-64 build" > script.sh
- docker run --rm --platform ${{ matrix.config.platform }} -v ${{ github.workspace }}/src:/app sf_builder
+ echo "cd src && export LDFLAGS='-static' && make clean && make -j4 ARCH=ppc-64 build" > script.sh
+ docker run --rm --platform ${{ matrix.config.platform }} -v ${{ github.workspace }}:/app sf_builder
../tests/signature.sh $benchref
# Other tests related to #5564 |
@Disservin It didn't work. Is workflow cwd
|
91e57c9
to
7549532
Compare
Changed Dockerfile to run |
Ah yes that too, thank.s |
This patch extracts the net downloading script in Makefile into an external script file. Also the script is moderately rewritten for improved readability and speed. * Use wget preferentially over curl, as curl is known to have slight overhead. * Use command instead of hash to check if command exists. Reportedly, hash always returns zero in some POSIX shells even when the command fails. * Command existence checks (wget/curl, sha256sum) are performed only once at the beginning. * Each of common patterns is encapsulated in a function (get_nnue_filename, validate_network). * Print out error/warning messages to stderr. No functional change
Fixes official-stockfish#5564 No functional change Co-authored-by: MinetaS <[email protected]>
7549532
to
b428b5f
Compare
Note here: I read some issues today and one of them is about wget failing to connect on IPv6 (#4978). Although it's not even remotely close to Stockfish issue, if the default behavior of the command poses errors, I believe the logic has better be reverted back (detect and use |
This patch extracts the net downloading script in Makefile into an external script file. Also the script is moderately rewritten for improved readability and speed.
No functional change