-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Track the project name for a generator driver and report it via ETW #81036
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
This PR modifies public API files. Please follow the instructions at https://github.com/dotnet/roslyn/blob/main/docs/contributing/API%20Review%20Process.md for ensuring all public APIs are reviewed before merging. |
702be07 to
b01f7a8
Compare
| /// <param name="baseDirectory">Absolute path to the base directory used for file paths of generated files.</param> | ||
| /// <exception cref="ArgumentException"><paramref name="baseDirectory"/> is not an absolute path.</exception> | ||
| public GeneratorDriverOptions(IncrementalGeneratorOutputKind disabledOutputs = IncrementalGeneratorOutputKind.None, bool trackIncrementalGeneratorSteps = false, string? baseDirectory = null) | ||
| public GeneratorDriverOptions(IncrementalGeneratorOutputKind disabledOutputs = IncrementalGeneratorOutputKind.None, bool trackIncrementalGeneratorSteps = false, string? baseDirectory = null, string? projectName = null) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@333fred Do we need to go thru an API review meeting for this, or is it ok to just do it via mail?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Think an email is fine.
| additionalTexts, | ||
| generatedFilesBaseDirectory); | ||
| generatedFilesBaseDirectory, | ||
| $"{projectState.Name} ({projectState.Id})"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we also be passing a project name, or some name, when doing this on the command line?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, that's a good idea.
Pass in assembly name as tracking name from the command line compiler
When there are multiple projects building in parallel (such as in a VS solution) the current generator telemetry doesn't allow you to know from which project each invocation of the generator is coming from.
This adds an optional value to the generator options where a caller can add a project name. It populates that from the tooling to pass in the project name + id.