-
Notifications
You must be signed in to change notification settings - Fork 324
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
Fix DevSetupAgent logging and some other fixes. #2566
Conversation
HyperVExtension/src/HyperVExtension/Helpers/DevSetupAgentDeploymentHelper.cs
Outdated
Show resolved
Hide resolved
I think we should keep all the Logs under the Logs folder, so instead of From my understanding of how future enhancements to let FeedbackHub collect logs would work, using this new place would be a headache. |
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.
Log location comment. See
Environment.SetEnvironmentVariable("DEVHOME_LOGS_ROOT", Path.Join(Helpers.Logging.LogFolderRoot, "CoreWidgets")); |
@krschau , I don't understand what you are asking for referring to devhome/extensions/CoreWidgetProvider/Program.cs. Please clarify. As for the actual location: %localappdata%\TempState normally does not exist and is not documented. Currently, Dev Home logs go under %localappdata%\Packages<PackageFamilyName>\TempState\Logs. Code changed in this PR is not part of Dev Home packaged app and doesn't have package identity and cannot write logs under that location. Furthermore, DevSetupAgent runs under LocalSystem account and cannot write logs under some user's account where Dev Home may exist. |
|
||
if (PInvoke.MakeAbsoluteSD(securityDescriptor, absolutSd, ref absoluteSdSize, null, ref daclSize, null, ref saclSize, ownerSid, ref ownerSize, groupSid, ref groupSize)) | ||
{ | ||
throw new HResultException(HRESULT.E_UNEXPECTED); |
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.
Suggestion: Add a brief message describing the error and where it failed.
Sorry, I assumed this was part of the extension and could write to the Dev Home logs. |
Summary of the pull request
DevSetupAgent and DevSetupEngine were crashing on start after previous (#2474) change to logging setup.
This change
%localappdata%\Temp\DevSetupEngine\Logs\HyperV directory (like C:\Users\LocalAdmin\AppData\Local\Temp\DevSetupEngine\Logs\HyperV for DevSetupgent)
Validation steps performed
Tested DevSetupAgent setup, start and configuration workflow on a Hyper-V VM.
PR checklist