-
Notifications
You must be signed in to change notification settings - Fork 5.3k
Closed
Labels
area-Extensions-Loggingbuggood first issueIssue should be easy to implement, good for first-time contributorsIssue should be easy to implement, good for first-time contributorshelp wanted[up-for-grabs] Good issue for external contributors[up-for-grabs] Good issue for external contributors
Milestone
Description
Repro code:
public static partial class ABC
{
[LoggerMessage(EventId = 0, Level = LogLevel.Debug, Message = "{foo}")]
static partial void M1(ILogger logger);
}For TemplateHasNoCorrespondingArgument, instead of passing 't' as an argument to the diag method, it should be passing t.Key (the name of the template).
runtime/src/libraries/Microsoft.Extensions.Logging.Abstractions/gen/LoggerMessageGenerator.Parser.cs
Line 326 in 43b1f2c
| Diag(DiagnosticDescriptors.TemplateHasNoCorrespondingArgument, ma.GetLocation(), t); |
Actual
Template [foo, foo] is not provided as argument to the logging method
Expected
Template "foo" is not provided as argument to the logging method
cc: @geeknoid
Metadata
Metadata
Assignees
Labels
area-Extensions-Loggingbuggood first issueIssue should be easy to implement, good for first-time contributorsIssue should be easy to implement, good for first-time contributorshelp wanted[up-for-grabs] Good issue for external contributors[up-for-grabs] Good issue for external contributors