Files
Stefan Broenner 501cbb2284 fix: add specific exception types to bare catches in production code (#321)
Fixes cs/catch-of-all-exceptions CodeQL alerts by adding specific exception
types to bare catch blocks in COM interop code.

Changes:
- PowerQueryCommands.Lifecycle.cs: 6 catches fixed with COMException/TargetInvocationException filters
- OlapPivotTableFieldStrategy.cs: 13 catches fixed with COMException/RuntimeBinderException filters
- PivotTableCommands.cs: 4 catches fixed with COMException/RuntimeBinderException filters
- NumberFormatTranslator.cs: 1 catch fixed with COMException/RuntimeBinderException filter
- DaxFormulaTranslator.cs: 1 catch fixed with COMException/RuntimeBinderException filter
- ConnectionCommands.Lifecycle.cs: 1 catch fixed with COMException

Also updates CodeQL configuration to exclude test files from catch-of-all-exceptions
rule since test cleanup code intentionally catches all exceptions for best-effort teardown.

Total: 26 bare catches fixed in production code, test exclusions configured.

Verified: Build succeeds with 0 warnings, 59 PowerQuery tests pass.

Co-authored-by: Stefan Broenner <stefan.broenner@microsoft.comm>
2025-12-16 21:08:24 +01:00
..