Repository navigation
MAINT: Make PlaywrightCopilotTarget's private helpers keyword-only - #4680
Open
Aditya Malkar (adimalkar) wants to merge 1 commit into
Open
Aditya Malkar (adimalkar) wants to merge 1 commit into
Aditya Malkar (adimalkar) wants to merge 1 commit into
Conversation
The five private extraction and wait helpers now take their parameters after `*`; their callers and the tests that call them directly pass arguments by name. Remove their entries from the keyword-only baseline. Relates to microsoft#4216
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues are recorded for the five-helper keyword-only migration.
No open issues 🎉
What changed in this PR
This PR advances #4216’s keyword-only migration by updating five private PlaywrightCopilotTarget helpers and their callers, without changing their implementation logic.
Changes:
- Make the five helpers keyword-only and update internal calls to use named arguments.
- Update direct unit-test calls and one mock assertion.
- Remove the five migrated signatures from the keyword-only baseline.
| File | Description |
|---|---|
tests/unit/prompt_target/target/test_playwright_copilot_target.py |
Align test calls and the mock assertion with keyword-only signatures. |
pyrit/prompt_target/playwright_copilot_target.py |
Make five private helpers keyword-only and update internal callers. |
build_scripts/keyword_only_baseline.txt |
Remove the five migrated helper entries. |
Review effort: Balanced
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Make the five private helpers of
PlaywrightCopilotTargetkeyword-only, and clear them from the keyword-only baseline._extract_content_if_ready_async,_extract_images_from_message_groups_async,_extract_multimodal_content_async,_extract_text_from_message_groups_asyncand_wait_for_images_to_stabilize_asynctake their parameters after*.assert_awaited_once_with) intests/unit/prompt_target/target/test_playwright_copilot_target.py.build_scripts/keyword_only_baseline.txt.python -m build_scripts.check_keyword_only_paramspasses, the target's 68 unit tests pass, andtyis clean on the file.Relates to #4216
This change was developed with AI assistance (Claude Code).