-
Notifications
You must be signed in to change notification settings - Fork 156
Labels
enhancementNew feature or requestNew feature or requestgoPull requests that update go codePull requests that update go codetech-debt
Description
Summary
Toolhive depends on signal.Notify in numerous places. In isolation, signal.Notify is not a problem, but relying on it in many places can create confusing and non-deterministic shutdown behavior.
Outside of main.go files, we should instead rely on clearer patterns for shutdown (e.g. context cancellation or ideally, callers invoking shutdown functions in deterministic order). Even with such patterns in place, we should discourage additional use of signal.Notify via a lint rule, so that all toolhive systems have easily maintainable shutdown behavior.
Definition of Done
A lint rule prevents use of signal.Notify or signal.NotifyContext outside of main.go files.
Existing callers outside of main.go are either removed or grandfathered in as ignored.
Additional Context
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requestgoPull requests that update go codePull requests that update go codetech-debt