-
Notifications
You must be signed in to change notification settings - Fork 101
Open
Labels
breaking-changeThis PR introduces a breaking change or the resolution of this issue may require a breaking change.This PR introduces a breaking change or the resolution of this issue may require a breaking change.tech-debtIssues tracking technical debt that we're carrying.Issues tracking technical debt that we're carrying.
Milestone
Description
Module version
v0.14.0
Use-cases
attr.Value
in the framework type system must be able to return their associated attr.Type
. This is handled via the Type(context.Context) attr.Type
method today. While the appropriate context.Context
is generally available, there are places where it may not be, such as types
package value creation functions.
Attempted Solutions
Either adding context.Context
to all potential callers that may eventually call Type()
or working around it via:
ctx := context.Background()
// ... Type(ctx) ...
Proposal
Type information should be very static and not require special logic where the context.Context
is especially helpful (e.g. logging). Therefore, we may be able to drop the parameter to remove this awkwardness.
References
ewbankkit
Metadata
Metadata
Assignees
Labels
breaking-changeThis PR introduces a breaking change or the resolution of this issue may require a breaking change.This PR introduces a breaking change or the resolution of this issue may require a breaking change.tech-debtIssues tracking technical debt that we're carrying.Issues tracking technical debt that we're carrying.