Skip to content

Only enforce context-only when a context.Context is within scope #29

Closed
@ktarplee

Description

@ktarplee

#13 added context-only but it is not very useful when in some functions you do not have a context passed in. I either need to add no lint to all the call sites where there is no context or I need to disable the linter. The linter is useful so I would prefer that the linter only enforce context-only when a variable of type context.Context is passed into the function or better yet within the scope when the log method is called. If not context.Context is present then it is not a lint issue if we call log.Info().

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions