Skip to content

Comments

fix: correct operator precedence in install command validation#365

Open
Xyc2016 wants to merge 1 commit intoComfy-Org:mainfrom
Xyc2016:fix-specify-commit
Open

fix: correct operator precedence in install command validation#365
Xyc2016 wants to merge 1 commit intoComfy-Org:mainfrom
Xyc2016:fix-specify-commit

Conversation

@Xyc2016
Copy link
Contributor

@Xyc2016 Xyc2016 commented Feb 17, 2026

Fixed issue #335: --pr cannot be used with --version or --commit

The condition "pr and version not in {None, "nightly"} or commit" was evaluated incorrectly due to operator precedence. Added parentheses to ensure the logic only triggers error when --pr is actually combined with conflicting flags, not when only --commit is specified.

@dosubot dosubot bot added size:XS This PR changes 0-9 lines, ignoring generated files. bug Something isn't working labels Feb 17, 2026
@codecov
Copy link

codecov bot commented Feb 17, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

@@           Coverage Diff           @@
##             main     #365   +/-   ##
=======================================
  Coverage   52.49%   52.49%           
=======================================
  Files          32       32           
  Lines        3568     3568           
=======================================
  Hits         1873     1873           
  Misses       1695     1695           
Files with missing lines Coverage Δ
comfy_cli/cmdline.py 49.39% <100.00%> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Fixed issue Comfy-Org#335: --pr cannot be used with --version or --commit

The condition "pr and version not in {None, \"nightly\"} or commit" was
evaluated incorrectly due to operator precedence. Added parentheses
to ensure the logic only triggers error when --pr is actually combined
with conflicting flags, not when only --commit is specified.

Co-Authored-By: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working size:XS This PR changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant