Repository navigation
Conversation
… fallbacks Co-authored-by: pelikhan <[email protected]>
Copilot
AI
changed the title
[WIP] Fix ignored errors and discarded results in lint findings
Handle ignored errors and discarded results
Oct 25, 2026
pelikhan
marked this pull request as ready for review
October 25, 2026 13:40
Contributor
There was a problem hiding this comment.
🔵 Needs a closer look
Cross-cutting error-handling changes need human validation, and unresolved failure-path issues remain.
3 open issues
What changed in this PR
This PR improves error handling across gh-aw’s compiler, parser, CLI, and console, addressing ignored results while preserving tolerant parsing and best-effort cleanup.
Changes:
- Propagates selected scanner, compiler-validation, temporary-file, and command-output failures.
- Logs cleanup and rendering failures and makes optional-field type checks explicit.
- Adds regressions for oversized lines, failed writes, malformed metadata, and traversal errors.
| File | Description |
|---|---|
pkg/workflow/tools.go |
Checks event-map and event-type assertions explicitly. |
pkg/workflow/skills_frontmatter.go |
Checks skill-reference types before use. |
pkg/workflow/samples_validation.go |
Uses typed lookups while preserving schema fallbacks. |
pkg/workflow/samples_replay.go |
Checks sampled workflow-name types. |
pkg/workflow/safe_outputs_data_schema.go |
Makes schema-type checks explicit. |
pkg/workflow/safe_outputs_call_workflow.go |
Uses typed tool-schema lookups. |
pkg/workflow/runtime_overrides.go |
Uses typed runtime-option lookups. |
pkg/workflow/run_step_sanitizer.go |
Checks environment and step-name lookups. |
pkg/workflow/resolve.go |
Logs lock-file close failures. |
pkg/workflow/plugins_frontmatter.go |
Checks plugin-reference types before use. |
pkg/workflow/observability_otlp.go |
Makes optional telemetry-field lookups explicit. |
pkg/workflow/mcp_setup_gateway.go |
Separates GitHub-tool presence from map lookup. |
pkg/workflow/linear_safe_outputs.go |
Checks configuration-map assertions. |
pkg/workflow/jira_tools.go |
Checks authentication and URL field types. |
pkg/workflow/drive_memory_config.go |
Uses the tolerant boolean helper. |
pkg/workflow/dependabot_reconcile.go |
Checks ecosystem and dependency-name types. |
pkg/workflow/copilot_logs.go |
Checks wire-request field assertions. |
pkg/workflow/compiler_yaml_step_conversion.go |
Uses a typed step-name lookup. |
pkg/workflow/compiler_yaml_main_job.go |
Propagates allowed-domain computation errors. |
pkg/workflow/compiler_yaml_main_job_test.go |
Tests malformed-model rejection before execution. |
pkg/workflow/compiler_github_mcp_steps.go |
Checks GitHub guard configuration types. |
pkg/workflow/compiler_difc_proxy.go |
Makes proxy configuration lookups explicit. |
pkg/workflow/comment_memory.go |
Checks optional configuration-map assertions. |
pkg/workflow/close_entity_helpers.go |
Uses a typed configuration-map lookup. |
pkg/workflow/assign_to_user.go |
Uses a typed assignment configuration lookup. |
pkg/workflow/add_reviewer.go |
Uses a typed reviewer configuration lookup. |
pkg/typeutil/lookup.go |
Makes boolean assertion handling explicit. |
pkg/typeutil/lookup_test.go |
Tests tolerant boolean parsing. |
pkg/scanfindings/scanfindings.go |
Stops rendering after a write failure. |
pkg/scanfindings/scanfindings_test.go |
Tests rendering termination on failed writes. |
pkg/parser/remote_resolve_sha.go |
Logs API response-close failures. |
pkg/parser/remote_download_file.go |
Logs download response-close failures. |
pkg/parser/remote_client.go |
Logs contents-response close failures. |
pkg/parser/include_processor.go |
Returns include-scanner completion errors. |
pkg/parser/include_expander.go |
Removes one scanner limit and checks another scanner’s errors. |
pkg/parser/include_expander_relativize_test.go |
Tests oversized lines and include-scanner failures. |
pkg/parser/import_schema_validation.go |
Makes optional schema assertions explicit. |
pkg/parser/frontmatter_extraction_test.go |
Tests markdown-section scanner failures. |
pkg/parser/frontmatter_content.go |
Returns markdown-section scanning errors. |
pkg/fileutil/fileutil.go |
Logs source-file close failures. |
pkg/console/verbose.go |
Logs verbose-output write failures. |
pkg/console/terminal.go |
Checks terminal-control and banner writes. |
pkg/console/spinner.go |
Logs spinner execution and output failures. |
pkg/console/prompt_form.go |
Returns setup-write errors and logs cleanup failures. |
pkg/console/print.go |
Logs shared message-output failures. |
pkg/console/output_failure_test.go |
Tests prompt failures and spinner cleanup. |
pkg/console/list.go |
Returns list-output errors before reading input. |
pkg/console/console.go |
Checks composed-section output writes. |
pkg/console/confirm.go |
Returns confirmation-output errors before reading input. |
pkg/console/banner.go |
Logs banner write failures. |
pkg/cli/zizmor.go |
Iterates completion messages without a scanner limit. |
pkg/cli/update_workflows.go |
Logs update response-close failures. |
pkg/cli/update_github_api.go |
Checks contextual client types and response cleanup. |
pkg/cli/update_extension_check.go |
Logs buffered upgrade-output replay failures. |
pkg/cli/typeassertion_diagnostics_test.go |
Tests malformed optional metadata and tolerant fallbacks. |
pkg/cli/trial_repository.go |
Logs confirmation-input errors without blocking setup. |
pkg/cli/token_usage_subagent_session.go |
Logs token-usage session close failures. |
pkg/cli/shellcheck.go |
Checks metadata types and temporary-file cleanup errors. |
pkg/cli/shellcheck_test.go |
Tests temporary scripts and malformed step metadata. |
pkg/cli/scanner_diagnostics_test.go |
Tests oversized records, includes, and scanner output. |
pkg/cli/retry.go |
Logs repeat-status output failures. |
pkg/cli/redacted_domains.go |
Logs domain-log close failures. |
pkg/cli/project_command.go |
Uses the string helper for status-field IDs. |
pkg/cli/observability_insights.go |
Stops insight rendering on write failure. |
pkg/cli/model_routing.go |
Logs traversal and routing-file close failures. |
pkg/cli/model_routing_session.go |
Logs routing-session close failures. |
pkg/cli/mcp_safe_update_cache.go |
Handles cache close errors and removes incomplete files. |
pkg/cli/mcp_safe_update_cache_test.go |
Tests manifest-cache writing and creation failures. |
pkg/cli/mcp_registry.go |
Logs registry response-close failures. |
pkg/cli/mcp_inspect_mcp.go |
Logs MCP session-close failures. |
pkg/cli/logs_rate_limit.go |
Checks rate-limit warning writes. |
pkg/cli/logs_github_rate_limit_usage.go |
Logs rate-limit file-close failures. |
pkg/cli/logs_format_tsv.go |
Stops TSV rendering and logs failed writes. |
pkg/cli/logs_download_zip.go |
Logs archive and entry close failures. |
pkg/cli/includes.go |
Processes include lines without scanner token limits. |
pkg/cli/imports.go |
Replaces string-backed scanners with line iteration. |
pkg/cli/import_url_fetcher.go |
Logs HTTP response-close failures. |
pkg/cli/gateway_logs_timeline.go |
Logs timeline and event-file close failures. |
pkg/cli/gateway_logs_rpc.go |
Logs RPC message-file close failures. |
pkg/cli/gateway_logs_parsing.go |
Logs gateway-log close failures. |
pkg/cli/gateway_logs_mcp.go |
Logs tool-call source close failures. |
pkg/cli/forecast_metadata.go |
Uses tolerant concurrency boolean parsing. |
pkg/cli/firewall_policy.go |
Logs audit-file close failures. |
pkg/cli/firewall_log.go |
Logs firewall-log close failures. |
pkg/cli/experiments_fetch.go |
Parses evaluation records without scanner token limits. |
pkg/cli/edit_command.go |
Returns output errors and preserves file-close errors. |
pkg/cli/edit_command_test.go |
Tests edit-output failures without workflow mutation. |
pkg/cli/domains_command.go |
Uses a typed tools-map lookup. |
pkg/cli/deps_security.go |
Logs response-close and drain failures. |
pkg/cli/deps_outdated.go |
Logs proxy response-close and drain failures. |
pkg/cli/copilot_events_jsonl.go |
Logs event-file close failures. |
pkg/cli/copilot_agents.go |
Logs agent-list response-close failures. |
pkg/cli/copilot_agent.go |
Logs agent-log close failures. |
pkg/cli/compile_watch.go |
Logs watcher-close failures. |
pkg/cli/compile_update_check.go |
Logs release and probe response-close failures. |
pkg/cli/codemod_bash_allowlist_unsupported_engine.go |
Uses typed lookups while preserving fallback behavior. |
pkg/cli/cli_output_write_errors_test.go |
Tests renderer failures and preserved execution results. |
pkg/cli/cleanup_traversal_test.go |
Tests traversal continuation and error logging. |
pkg/cli/bootstrap_profile_github_app.go |
Checks listener cleanup and registration-page writes. |
pkg/cli/bootstrap_config.go |
Stops checklist rendering on write failure. |
pkg/cli/audit_threat_detection.go |
Logs threat-detection traversal and close failures. |
pkg/cli/audit_threat_detection_session.go |
Logs unified-session close failures. |
pkg/cli/audit_expanded.go |
Logs routing-artifact close failures. |
pkg/cli/audit_cross_run_clusters_render.go |
Checks cluster-report writes and stops on failure. |
pkg/cli/access_log.go |
Logs access-log close failures. |
cmd/gh-aw/output_write_errors_test.go |
Tests version and usage-output error propagation. |
cmd/gh-aw/main.go |
Returns version and usage-rendering write errors. |
Review effort: Max
| @@ -0,0 +1,73 @@ | |||
| package cli | |||
| } | ||
|
|
||
| func TestWriteTempScriptFileCreationFailure(t *testing.T) { | ||
| t.Setenv("TMPDIR", filepath.Join(t.TempDir(), "missing")) |
Comment on lines
+37
to
+41
| if _, err := fmt.Fprintf(w, "# %d runs | %s duration | %s tokens | %d turns | %d errors\n", | ||
| s.TotalRuns, s.TotalDuration, formatTSVSummaryTokens(s.TotalTokens), s.TotalTurns, s.TotalErrors); err != nil { | ||
| logsTSVLog.Printf("Failed to write TSV summary: %v", err) | ||
| return | ||
| } |
github-actions
Bot
deleted the
copilot/lint-monster-handle-ignored-errors
branch
November 3, 2026 02:02
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.


Unchecked errors could silently truncate parsed content, hide write failures, or discard compiler validation failures. This change handles actionable findings while preserving tolerant parsing and best-effort cleanup semantics.
strings.Builderorbytes.Buffer, which cannot return write errors. No suppressions or analyzer changes.