Skip to content

fix: remove unused WorkflowEvent import and restore 'invalid content' retry check#275

Merged
Roopan-Microsoft merged 1 commit into
devfrom
fix/restore-retry-and-remove-unused-import
Jun 5, 2026
Merged

fix: remove unused WorkflowEvent import and restore 'invalid content' retry check#275
Roopan-Microsoft merged 1 commit into
devfrom
fix/restore-retry-and-remove-unused-import

Conversation

@Dhanushree-Microsoft
Copy link
Copy Markdown
Contributor

Purpose

Addresses review comments from PR #273:

  1. Remove unused \WorkflowEvent\ import from \migration_processor.py\ — it was imported but never used in code (only referenced in a comment), causing lint failure (F401).

  2. Restore 'model produced invalid content' transient error retry in \�zure_openai_response_retry.py\ — this check existed on \main\ but was accidentally dropped during the agent-framework 1.3.0 refactor in PR fix: Refactor code structure for improved readability and maintainability #272. Without it, structured response validation failures from Azure OpenAI won't be retried.

Does this introduce a breaking change?

  • Yes
  • No

… retry check

- Remove unused WorkflowEvent import from migration_processor.py (fixes lint F401)
- Restore 'model produced invalid content' transient error retry in
  azure_openai_response_retry.py (regression from agent-framework 1.3.0 refactor)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 5, 2026

Coverage

Coverage Report •
FileStmtsMissCoverMissing
TOTAL309720893% 
report-only-changed-files is enabled. No files were changed during this commit :)

Tests Skipped Failures Errors Time
588 0 💤 0 ❌ 0 🔥 24.025s ⏱️

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 5, 2026

Coverage

Processor Coverage Report •
FileStmtsMissCoverMissing
src/processor/src/libs/agent_framework
   azure_openai_response_retry.py37114062%91, 201, 209, 231, 257, 267–269, 393, 400–403, 405–407, 413–415, 432, 453–454, 459–462, 465–468, 470–473, 475, 485–487, 489–492, 494–497, 499–503, 505, 513–515, 517, 540–545, 547–549, 555–556, 560–563, 567, 570, 578–579, 585–586, 591, 593, 614, 620–622, 626–627, 643–644, 646–649, 653, 656, 664–665, 671–673, 675–678, 680–691, 694, 701–702, 727–728, 735–736, 738, 742, 745–746, 750–751, 753–755, 763, 765–767, 769–771, 773–774, 784
src/processor/src/steps
   migration_processor.py2644084%88–89, 145–146, 160, 187, 222–223, 229–230, 234, 238, 309–312, 315–318, 322–323, 336–337, 395–396, 496–497, 547–548, 555–556, 594–595, 613–614, 678–679, 703, 732
TOTAL575273487% 

Tests Skipped Failures Errors Time
812 0 💤 0 ❌ 0 🔥 20.356s ⏱️

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR addresses follow-up items from prior review by removing an unused WorkflowEvent import that caused lint failures and by restoring a dropped transient-retry condition for Azure OpenAI “invalid content” errors during the agent-framework 1.3.0 refactor.

Changes:

  • Removed unused WorkflowEvent import from migration_processor.py to resolve F401.
  • Re-added detection of “model produced invalid content” / “invalid content” as a retryable transient error in Azure OpenAI response retry logic.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
src/processor/src/steps/migration_processor.py Removes an unused import to fix linting.
src/processor/src/libs/agent_framework/azure_openai_response_retry.py Restores retry classification for Azure OpenAI “invalid content” transient failures.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@Roopan-Microsoft Roopan-Microsoft merged commit 9fd191d into dev Jun 5, 2026
14 checks passed
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.

4 participants