Fix for macOS: tar: Option --to-command=... is not supported #188
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Opening as a bug report, also happens when running
tox -e py312locally on macOS:=================================== FAILURES =================================== _____________________ test_check_doc_unreleased_version_ok _____________________ monkeypatch = <_pytest.monkeypatch.MonkeyPatch object at 0x1061f9d30> tmp_path = PosixPath('/private/var/folders/g6/rgtlsw6n123b0gt5483s5_cm0000gn/T/pytest-of-runner/pytest-0/test_check_doc_unreleased_vers2') def test_check_doc_unreleased_version_ok(monkeypatch, tmp_path: Path) -> None: prepare_fake_docs( tmp_path, "<div>New in 3.13</div>", ) db = { "release": Tag("3.13.0rc1"), "git_repo": str(tmp_path), } > run_release.check_doc_unreleased_version(cast(ReleaseShelf, db)) tests/test_run_release.py:100: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ run_release.py:582: in check_doc_unreleased_version if not ask_question("Are these `(unreleased)` strings in built docs OK?"): run_release.py:258: in ask_question answer = input("Enter yes or no: ") _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.capture.DontReadFromInput object at 0x103ce[45](https://github.com/hugovk/release-tools/actions/runs/11601299635/job/32303698930#step:5:46)60>, size = -1 def read(self, size: int = -1) -> str: > raise OSError( "pytest: reading from stdin while output is captured! Consider using `-s`." ) E OSError: pytest: reading from stdin while output is captured! Consider using `-s`. .tox/py/lib/python3.12/site-packages/_pytest/capture.py:205: OSError ----------------------------- Captured stdout call ----------------------------- Checking built docs for '(unreleased)' Are these `(unreleased)` strings in built docs OK? Enter yes or no: ----------------------------- Captured stderr call ----------------------------- tar: Option --to-command=! grep -Hn --label="$TAR_FILENAME" "[(]unreleased[)]" is not supported Usage: List: tar -tf <archive-filename> Extract: tar -xf <archive-filename> Create: tar -cf <archive-filename> [filenames...] Help: tar --helphttps://man.freebsd.org/cgi/man.cgi?bsdtar(1) has no mention of
--to-command.However, GNU tar does have
--to-command, which is presumably the GNU/Linux one:https://www.gnu.org/software/tar/manual/html_node/Writing-to-an-External-Program.html
This was added in #164, cc @encukou.