Refactor: deduplicate missing-issue handler wrappers via descriptor registry and merge conclusion steps#28255
Closed
Refactor: deduplicate missing-issue handler wrappers via descriptor registry and merge conclusion steps#28255
Conversation
4 tasks
Agent-Logs-Url: https://github.com/github/gh-aw/sessions/a370dc91-9538-4534-ad0f-0a2c3cc5ca59 Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix duplicate code: missing-issue wrapper pattern in setup/js
Refactor: deduplicate missing-issue handler wrappers via descriptor registry
Apr 24, 2026
This was referenced Apr 24, 2026
…ecord missing messages step Agent-Logs-Url: https://github.com/github/gh-aw/sessions/c20b5a8c-16d0-43b2-bd84-9db2339c189e Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Contributor
Author
Done in 4ea882f. The two compiler-generated steps ("Record missing tool" and "Record incomplete") are now merged into a single "Record missing messages" step ( Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
Copilot
AI
changed the title
Refactor: deduplicate missing-issue handler wrappers via descriptor registry
Refactor: deduplicate missing-issue handler wrappers via descriptor registry and merge conclusion steps
Apr 24, 2026
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.
Three
create_*handler files shared ~40 lines of identical scaffolding aroundbuildMissingIssueHandler(...), differing only in per-handler config values and item renderers — a maintenance hazard requiring synchronized edits across files. Additionally, the compiler-generated conclusion job contained two separate steps for recording missing messages that were effectively no-ops.Changes
missing_issue_handler_registry.cjs— single source of truth for all three handler descriptors; builds ahandlerRegistryMap via one shared factory loop overHANDLER_DESCRIPTORS:New
missing_issue_handler_registry.test.cjs(26 tests) — validates descriptor fields, registry coverage, per-handler rendering callbacks (renderCommentItem,renderIssueItem,buildCommentHeader), and factory output for all three handler types.New
record_missing_messages.cjs— a proper standalone step script that replaces the two formerly separate (and non-functional) "Record missing tool" and "Record incomplete" steps. The script loads the agent output artifact once and processesmissing_tool,missing_data, andreport_incompletemessages in a single pass, setting step outputs (tools_reported,total_count,incomplete_count) and delegating GitHub issue creation to thehandlerRegistrywhen configured.Updated
notify_comment.go— the compiler now emits a single "Record missing messages" step (id: record_missing) whenever any ofmissing-tool,missing-data, orreport-incompleteis configured, replacing the two separate conditional step blocks and combining all relevant env vars.All 201 lock files recompiled to reflect the merged step.
New
record_missing_messages.test.cjs(11 tests) — validates config parsing from env vars andmain()output-setting behaviour.