Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 10 additions & 4 deletions tests/windows/test_cli_non_ascii_arg.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ def main():
# (#1952). One retry against a fresh cache separates that from a real
# CLI indexing failure.
ctrl_out = ""
ctrl_err = ""
for attempt in ("cache_ascii", "cache_ascii_retry"):
env = dict(os.environ)
env["CBM_CACHE_DIR"] = os.path.join(work, attempt)
Expand All @@ -81,14 +82,19 @@ def main():
json.dumps({"repo_path": ascii_repo})],
capture_output=True, timeout=120, env=env)
ctrl_out = (ctrl.stdout or b"").decode("utf-8", "replace")
ctrl_err = (ctrl.stderr or b"").decode("utf-8", "replace")
if '"nodes"' in ctrl_out:
break
print("SETUP: ASCII control attempt %r did not index via CLI:\n%s"
% (attempt, ctrl_out[:300]))
# Full stdout AND stderr: the reason lives on stderr (daemon
# spawn/handshake diagnostics), and a head slice of stdout only
# ever showed the allocator preamble.
print("SETUP: ASCII control attempt %r did not index via CLI (rc=%s):\n"
"stdout:\n%s\nstderr:\n%s"
% (attempt, ctrl.returncode, ctrl_out, ctrl_err))
time.sleep(2)
if '"nodes"' not in ctrl_out:
print("SETUP FAIL: ASCII control did not index via CLI:\n%s" %
ctrl_out[:300])
print("SETUP FAIL: ASCII control did not index via CLI:\nstdout:\n%s\nstderr:\n%s"
% (ctrl_out, ctrl_err))
return 2

env2 = dict(os.environ)
Expand Down
Loading
Loading