Skip to content

Fix: Include slave_id when moving tasks - #1390

Merged
greenbonebot merged 2 commits into
mainfrom
fix-move-task-slave-id
Oct 9, 2026
Merged

greenbonebot merged 2 commits into
mainfrom
fix-move-task-slave-id

Conversation

@wiegandm

@wiegandm wiegandm commented Oct 8, 2026

Copy link
Copy Markdown
Member

What

Default move_task() to the master scanner by sending slave_id="" in GMPv224-derived clients (including GMPv227) and GMPNext. Reject an explicit None rather than generating an invalid request. Update docstrings and tests for default, empty, nonempty, and None values.

Why

GMP requires a slave_id attribute for move_task; omitting it caused gvmd to return 400 instead of moving the task to the master scanner.

References

Checklist

  • I have added tests for the changes
  • I have used the following LLMs/AI tools in this pull request: pi coding agent (openai-codex/gpt-6-sol) to implement and review the fix and prepare the local commit and PR description

Send an empty slave_id for the master by default and reject explicit None instead of omitting the required attribute. Cover default, master, slave, and invalid values in request and client tests.

Commit generated using the `pi` coding agent harness (model: openai-codex/gpt-6-sol).
@wiegandm
wiegandm requested a review from a team as a code owner October 8, 2026 12:56
@greenbonebot
greenbonebot enabled auto-merge (rebase) October 8, 2026 12:56
@github-actions

github-actions Bot commented Oct 8, 2026 •

Copy link
Copy Markdown

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Snapshot Warnings

⚠️: No snapshots were found for the head SHA be71c3c.
Ensure that dependencies are being submitted on PR branches and consider enabling retry-on-snapshot-warnings. See the documentation for more information and troubleshooting advice.

Scanned Files

None

@github-actions

github-actions Bot commented Oct 8, 2026 •

Copy link
Copy Markdown

Conventional Commits Report

Type Number
Bug Fixes 2

🚀 Conventional commits found.

@codecov

codecov Bot commented Oct 8, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.40%. Comparing base (c5e320f) to head (be71c3c).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1390   +/-   ##
=======================================
  Coverage   98.40%   98.40%           
=======================================
  Files         106      106           
  Lines        6886     6888    +2     
  Branches     1244     1244           
=======================================
+ Hits         6776     6778    +2     
  Misses         77       77           
  Partials       33       33           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Match Ruff formatting for the GMPv224 and GMPNext move_task methods.

Commit generated using the `pi` coding agent harness (model: openai-codex/gpt-6-sol).
@greenbonebot
greenbonebot merged commit df73459 into main Oct 9, 2026
26 checks passed
@greenbonebot
greenbonebot deleted the fix-move-task-slave-id branch October 9, 2026 06:19
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.

3 participants