Closed etiennehucklemarchand closed 4 years ago
@erich-wang , please look in this similar issue.
Same for version 1.8.1
I've ran into the exact same issue and had to downgrade. Been blowing up my PoSH Transcripts.
In this case you could safely ignore the LoaderExceptions in $Error variables since the missing assembly will be loaded just after the error, it should not affect any other cmdlets. We understand you may check $Error in your script, we'll address this issue in the near future and will update the progress in this thread, thanks.
In this case you could safely ignore the LoaderExceptions in $Error variables since the missing assembly will be loaded just after the error, it should not affect any other cmdlets. We understand you may check $Error in your script, we'll address this issue in the near future and will update the progress in this thread, thanks.
@erich-wang , Thanks for your reply! You're right, the LoaderExceptions don't affect other cmdlets; our scripts are running fine (nothing has been reported so far). We actually check the $Error variable in some of our scripts, so we have to ensure the variable's empty prior execution. We currently do the following: $error.clear()
to empty the variable.
In this case you could safely ignore the LoaderExceptions in $Error variables since the missing assembly will be loaded just after the error, it should not affect any other cmdlets. We understand you may check $Error in your script, we'll address this issue in the near future and will update the progress in this thread, thanks.
Are you sure about this? I noticed there are 4 dlls within PreloadAssemblies that don't get imported. When I run the import the second time, all but Microsoft.Azure.PowerShell.Authenticators.dll are ok.
Yes, I'm sure, and you may verify that all assemblies should be loaded after import-module. Anyhow, we'll eliminate the LoaderExceptions errors in the near feature and will update this thread.
Closet this issue as it is resolved in Az 4.3. Please reopen this issue or create new issue if any concern, thanks.
Description
Since a PowerShell Az module upgrade, the Az.Accounts module has trouble loading. The failure is caught by $ERROR environment variable. The variable gets filled-in when importing the Az.Accounts modules, when opening a PowerShell session or console. It seems to have trouble with one of its dependencies:
Getting more information on the error above by running
It outputs the following:
Environment data
Module versions
Debug output
N/A
Error output
N/A