You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Dynamo crashing when C:\ProgramData\Dynamo doesn't exist.
Due that C:\ProgramData\Dynamo folder is not created any more then the code was expecting that folder to exist so Dynamo was crashing. I moved the code inside the try/catch and also added a validation that just execute the code if the directory exists.
Due that C:\ProgramData\Dynamo folder is not created any more then the code was expecting that folder to exist so Dynamo was crashing.
I moved the code inside the try/catch and also added a validation that just execute the code if the directory exists.
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR fixes a crash that occurs when the C:\ProgramData\Dynamo directory does not exist. The fix moves the directory access code inside the existing try-catch block and adds a validation check to ensure the directory exists before attempting to access it.
Key Changes
Added directory existence validation before attempting to read XML files
Moved the try-catch block to encompass the directory access logic
There appears to be an extra closing brace at line 581. The try-catch block should close at line 580, but line 581 suggests an additional scope is being closed that isn't shown in the diff. Verify that the brace structure is correct in the full file context.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Purpose
Dynamo crashing when C:\ProgramData\Dynamo doesn't exist.
Due that C:\ProgramData\Dynamo folder is not created any more then the code was expecting that folder to exist so Dynamo was crashing. I moved the code inside the try/catch and also added a validation that just execute the code if the directory exists.
Declarations
Check these if you believe they are true
Release Notes
Dynamo crashing when C:\ProgramData\Dynamo doesn't exist.
Reviewers
@QilongTang @zeusongit
FYIs
@jnealb