Skip to content

Remove Ruff FBT002 suppression and require explicit boolean arguments#263

Draft
Copilot wants to merge 3 commits into
mainfrom
copilot/fbt002-fix-linter-error-one-more-time
Draft

Remove Ruff FBT002 suppression and require explicit boolean arguments#263
Copilot wants to merge 3 commits into
mainfrom
copilot/fbt002-fix-linter-error-one-more-time

Conversation

Copilot AI commented Jun 3, 2026

Copy link
Copy Markdown
Contributor

This PR addresses the FBT002 lint debt by removing the global suppression and updating affected APIs to avoid boolean default positional parameters. The change set keeps existing behavior while making boolean intent explicit at call sites.

  • Ruff configuration

    • Removed FBT002 from /tmp/workspace/GitHubSecurityLab/seclab-taskflow-agent/pyproject.toml ignore list so new violations are enforced.
  • Signature updates (explicit booleans)

    • Updated functions/methods that used boolean defaults (including CLI, runner/render paths, template utilities, and CodeQL helper code) to require explicit boolean arguments.
    • Where needed, used keyword-only required booleans to preserve call-site readability and avoid positional ambiguity.
  • Call-site alignment

    • Updated all affected invocations to pass explicit values (e.g., headless=headless, log=True, async_task=False).
  • Behavior compatibility

    • Preserved Jinja template env(...) flexibility by keeping optional required behavior through the registered wrapper while conforming the underlying function signature to explicit booleans.
# before
async def render_model_output(data: str, log: bool = True, async_task: bool = False, task_id: str | None = None) -> None: ...

# after
async def render_model_output(data: str, log: bool, async_task: bool, task_id: str | None = None) -> None: ...

# call sites now pass intent explicitly
await render_model_output(message, log=True, async_task=False, task_id=None)

Copilot AI requested review from Copilot and removed request for Copilot June 3, 2026 10:46
Copilot AI linked an issue Jun 3, 2026 that may be closed by this pull request
Copilot AI requested review from Copilot and removed request for Copilot June 3, 2026 10:54
Copilot AI requested review from Copilot and removed request for Copilot June 3, 2026 10:57
Copilot AI changed the title [WIP] Fix linter error FBT002 and update suppression list Remove Ruff FBT002 suppression and require explicit boolean arguments Jun 3, 2026
Copilot AI requested a review from kevinbackhouse June 3, 2026 10:58
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.

FBT002

2 participants