Skip to content

Fix Windows man-page availability check - #1954

Open
ekanshul wants to merge 1 commit into
httpie:masterfrom
ekanshul:fix-windows-man-page-guard
Open

ekanshul wants to merge 1 commit into
httpie:masterfrom
ekanshul:fix-windows-man-page-guard

Conversation

@ekanshul

Copy link
Copy Markdown

The Windows short-circuit in is_available() compared os.system (the builtin function) to 'nt', so it was always false.

Use os.name == 'nt' instead, and add a regression test.

Closes #1898

os.system == 'nt' is always False because os.system is a function.
Use os.name == 'nt' so the guard actually skips man on Windows.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug: Windows guard in is_available() compares os.system (a function) to 'nt' — always False

1 participant