Skip to content

Conversation

@hiroyuki-sato
Copy link
Collaborator

@hiroyuki-sato hiroyuki-sato commented Aug 22, 2025

Rationale for this change

This is the sub issue #44748.

  • SC2086: Double quote to prevent globbing and word splitting
  • SC2012: Use find instead of ls to better handle non-alphanumeric filenames
shellcheck ci/scripts/python_test_emscripten.sh

In ci/scripts/python_test_emscripten.sh line 28:
cd ${build_dir}
   ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting.

Did you mean:
cd "${build_dir}"


In ci/scripts/python_test_emscripten.sh line 31:
pyodide_wheel=$(ls -t dist/pyarrow*.whl | head -1)
                ^---------------------^ SC2012 (info): Use find instead of ls to better handle non-alphanumeric filenames.


In ci/scripts/python_test_emscripten.sh line 34:
python scripts/run_emscripten_tests.py ${pyodide_wheel} --dist-dir=${pyodide_dist_dir} --runtime=node
                                       ^--------------^ SC2086 (info): Double quote to prevent globbing and word splitting.
                                                                   ^-----------------^ SC2086 (info): Double quote to prevent globbing and word splitting.

Did you mean:
python scripts/run_emscripten_tests.py "${pyodide_wheel}" --dist-dir="${pyodide_dist_dir}" --runtime=node


In ci/scripts/python_test_emscripten.sh line 37:
python scripts/run_emscripten_tests.py ${pyodide_wheel} --dist-dir=${pyodide_dist_dir} --runtime=chrome
                                       ^--------------^ SC2086 (info): Double quote to prevent globbing and word splitting.
                                                                   ^-----------------^ SC2086 (info): Double quote to prevent globbing and word splitting.

Did you mean:
python scripts/run_emscripten_tests.py "${pyodide_wheel}" --dist-dir="${pyodide_dist_dir}" --runtime=chrome

For more information:
  https://www.shellcheck.net/wiki/SC2012 -- Use find instead of ls to better ...
  https://www.shellcheck.net/wiki/SC2086 -- Double quote to prevent globbing ...

What changes are included in this PR?

  • SC2086: Quote variables.
  • SC2012: skip shellcheck.

Are these changes tested?

Yes.

Are there any user-facing changes?

No.

@github-actions
Copy link

⚠️ GitHub issue #47402 has been automatically assigned in GitHub to PR creator.

@github-actions github-actions bot added the awaiting review Awaiting review label Aug 22, 2025
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This part use ls with -t option, so we can't use echo.
I don't know alternate command which is usable on macOS / Linux.
(As far as I know, find and stat can't use the same option on macOS / Linux)

latest=$(python3 -c '
import glob, os
files = glob.glob("dist/pyarrow*.whl")
if files:
    print(max(files, key=os.path.getmtime))
')
echo "$latest"

@github-actions github-actions bot added awaiting committer review Awaiting committer review and removed awaiting review Awaiting review labels Aug 22, 2025
@hiroyuki-sato hiroyuki-sato force-pushed the topic/shellcheck-python_test_emscripten branch from 5b99b51 to 2e4daa4 Compare August 25, 2025 11:29
@hiroyuki-sato
Copy link
Collaborator Author

@kou CI has been passed. Please take a look when you get a chance.

@kou
Copy link
Member

kou commented Aug 26, 2025

@github-actions crossbow submit emscripten

@github-actions
Copy link

Revision: 2e4daa4

Submitted crossbow builds: ursacomputing/crossbow @ actions-ccceaf6e7f

Task Status
test-conda-python-emscripten GitHub Actions
test-ubuntu-22.04-cpp-emscripten GitHub Actions

…ipts/python_test_emscripten.sh"

This reverts commit 2e4daa4.
@hiroyuki-sato
Copy link
Collaborator Author

I reverted this change for testing test-conda-python-emscripten

@hiroyuki-sato
Copy link
Collaborator Author

@github-actions crossbow submit emscripten

@github-actions
Copy link

Unable to match any tasks for `emscripten`
The Archery job run can be found at: https://github.com/apache/arrow/actions/runs/17230344793

@hiroyuki-sato
Copy link
Collaborator Author

@github-actions crossbow submit test-conda-python-emscripten test-ubuntu-22.04-cpp-emscripten

@github-actions
Copy link

Revision: 46d2857

Submitted crossbow builds: ursacomputing/crossbow @ actions-80377eea67

Task Status
test-conda-python-emscripten GitHub Actions
test-ubuntu-22.04-cpp-emscripten GitHub Actions

@hiroyuki-sato
Copy link
Collaborator Author

test-conda-python-emscripten testing has been failed after revert this change. So, test-conda-python-emscripten failure unrelated this change.

@kou
Copy link
Member

kou commented Aug 26, 2025

OK. Let's complete #47330 before this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting committer review Awaiting committer review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants