Skip to content

[dead-code] chore: remove dead functions — 2 functions removed - #75187

Merged
pelikhan merged 1 commit into
mainfrom
chore/remove-dead-functions-42043106798-b642eede28b51b0f
Nov 5, 2026
Merged

pelikhan merged 1 commit into
mainfrom
chore/remove-dead-functions-42043106798-b642eede28b51b0f

Conversation

@github-actions

@github-actions github-actions Bot commented Nov 5, 2026

Copy link
Copy Markdown
Contributor

Functions Removed

Function File
VisitExpressionTree pkg/workflow/expression_parser.go
conditionalPattern.ReplaceAllStringFunc pkg/workflow/template_conditional_pattern.go

Tests Removed

  • TestVisitExpressionTree, TestVisitExpressionTreeWithError (expressions_test.go)
  • TestVisitExpressionTreeWithDifferentNodeTypes (expression_coverage_test.go)
  • Visitor assertions in TestParseExpressionIntegration (rendering check kept)

Verification

  • go build ./...
  • go vet ./...
  • go vet -tags=integration ./...
  • make fmt (fails in sandbox: prettier not installed; gofmt clean on changed files)

Note: 4 pkg/workflow tests (git credentials, enclave expiry) fail in the sandbox, unrelated to these deletions.

https://github.com/github/gh-aw/actions/runs/42043106798

Generated by 🧹 Dead Code Removal Agent · copilot · auto · ~97 AIC · ⌖ ~2 AIC · ⊞ 10.9K · ◷

  • expires on Nov 8, 2026, 6:41 AM UTC-08:00

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

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

The change removes the exported VisitExpressionTree API, potentially breaking downstream Go consumers while leaving the source-verified public API documentation inconsistent.

1 open issue
What changed in this PR

This pull request removes two unused workflow helpers and their dedicated tests while retaining expression parsing and rendering coverage. However, removing the exported VisitExpressionTree function is a breaking public API change, and the package README still documents it.

Changes:

  • Removes VisitExpressionTree and related visitor tests.
  • Removes conditionalPattern.ReplaceAllStringFunc and its unused import.
  • Retains expression parsing, rendering, and conditional-pattern coverage.
  • Requires API compatibility and documentation updates before approval.

This pull request requires changes.

File Description
pkg/​workflow/​template_conditional_pattern.go Removes the unused conditional-pattern replacement helper and import.
pkg/​workflow/​expressions_test.go Removes visitor-specific tests and updates integration coverage.
pkg/​workflow/​expression_parser.go Removes the exported VisitExpressionTree function.
pkg/​workflow/​expression_coverage_test.go Removes coverage tests for the deleted visitor.

Review effort: Lite (auto)

return nil
}

func BreakLongExpression(source string) []string {
@pelikhan
pelikhan marked this pull request as ready for review November 5, 2026 15:27
@pelikhan
pelikhan merged commit 7049514 into main Nov 5, 2026
10 checks passed
@pelikhan
pelikhan deleted the chore/remove-dead-functions-42043106798-b642eede28b51b0f branch November 5, 2026 15:27
@github-actions

github-actions Bot commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor Author

✅ Design Decision Gate 🏗️ completed the design decision gate check. See the comment below for the result and any generated ADR draft.

Design Decision Gate 🏗️

Outcome: reported_no_action

The agent completed and reported no action. A no-op output alone does not verify that all required work was completed or that publication was possible.

Agent messages are omitted from this comment. The category uses structured run status, not interpretation of agent prose.

Generated from Design Decision Gate 🏗️ · routed: opus55 medium · ~11 AIC · ⌖ ~2 AIC · ⊞ 7.7K · ◷

🏗️ ADR gate enforced by Design Decision Gate 🏗️

@github-actions

github-actions Bot commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor Author

✅ Ponytail Reviewer completed successfully!

Ponytail Reviewer

Outcome: reported_no_action

The agent completed and reported no action. A no-op output alone does not verify that all required work was completed or that publication was possible.

Agent messages are omitted from this comment. The category uses structured run status, not interpretation of agent prose.

Generated from Ponytail Reviewer · routed: gpt56 max · ~2 AIC · ⌖ ~1 AIC · ⊞ 118 · ◷

Generated by Ponytail Reviewer for #75187

@github-actions

github-actions Bot commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor Author

🧠 Matt Pocock Skills Reviewer has completed the skills-based review. ✅

🧠 Reviewed using Matt Pocock's skills by Matt Pocock Skills Reviewer

@github-actions

github-actions Bot commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor Author

✅ Test Quality Sentinel completed test quality analysis.

Test Quality Sentinel

Outcome: reported_no_action

The agent completed and reported no action. A no-op output alone does not verify that all required work was completed or that publication was possible.

Agent messages are omitted from this comment. The category uses structured run status, not interpretation of agent prose.

Generated from Test Quality Sentinel · routed: haiku55 xhigh · ~1 AIC · ⌖ ~1 AIC · ⊞ 6.3K · ◷

🧪 Test quality analysis by Test Quality Sentinel

@github-actions

github-actions Bot commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor Author

✅ PR Code Quality Reviewer completed the code quality review.

Warning

Threat detection engine error

Threat detection could not complete its analysis due to a tooling error. This is not a security finding.

What happened

The threat detection engine failed to produce results.

Review the workflow run logs to troubleshoot the error.

🔎 Code quality review by PR Code Quality Reviewer

@github-actions

github-actions Bot commented Nov 6, 2026

Copy link
Copy Markdown
Contributor Author

🎉 This pull request is included in a new release.

Release: v1.2.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants