Skip to content

Commit bff65bd

Browse files
ci: address Copilot review suggestions on instructions file
- Add missing tracing macro variants (warn!, error!) and unqualified forms (info!, debug!, warn!, error! via use tracing::{...}) - Fix error handling section: separate silently-swallowed errors (.ok(), let _ = result) from panicking operations (.unwrap()/.expect()) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 7a3cbdc commit bff65bd

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

.github/copilot-instructions.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,9 @@
33
## Security — PII and Secrets
44

55
Flag any logging statements (`log::info!`, `log::debug!`, `log::warn!`, `log::error!`,
6-
`tracing::info!`, `tracing::debug!`) that may log:
6+
`tracing::info!`, `tracing::debug!`, `tracing::warn!`, `tracing::error!`, or unqualified
7+
`info!`, `debug!`, `warn!`, `error!` macros (e.g., via `use tracing::{info, debug, warn, error}`))
8+
that may log:
79
- HTTP request/response headers (Authorization, Cookie, X-API-Key, or similar)
810
- HTTP request/response bodies or raw payloads
911
- User-identifiable fields (email, name, user_id, ip_address, phone)
@@ -19,5 +21,6 @@ block safe. If there is a safe alternative, suggest it.
1921

2022
## Security — Error Handling
2123

22-
Flag cases where errors are silently swallowed (empty `catch`, `.unwrap()` without
23-
context, `let _ = result`) in code paths that handle external input or network responses.
24+
Flag cases where errors are silently swallowed (empty `catch`, `.ok()` without
25+
handling, `let _ = result`) or where operations like `.unwrap()`/`.expect()` may panic,
26+
in code paths that handle external input or network responses.

0 commit comments

Comments
 (0)