quality.error-handling

Missing error context or logging

Catch blocks should include the caught error when they log or rethrow.

#Metadata

#Why it matters

Logging or rethrowing without the original error strips the context needed to diagnose the failure.

#Remediation

Pass the caught error to the logger or preserve it when constructing the replacement error.

#Repository path

The generated metadata points to critiq-rules/libs/rules/catalog/rules/typescript/ts.quality.missing-error-context.rule.yaml.