Exchange Online Compatibility?
Describe the bug
I'm attempting to use the Exchange Online Mangement module and it keeps crashing. The cmdlet successfully connects but soon after a Powershell exception is thrown.
The command I'm using is
connect-ExchangeOnline -userprinciplename <USERNAME>
The error message is:
Exception: C:\Program Files\WindowsPowerShell\Modules\ExchangeOnlineManagement\2.0.5\netCore\ExchangeOnlineManagement.psm1:475
Line |
475 | … PSSession = New-ExoPSSession -ExchangeEnvironmentName $ExchangeEnviro …
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| An error has occurred which PowerShell cannot handle. A remote session might have
| ended.
I am able to use this command successfully in the windows powershell console; the error is only thrown in Jupyter and in VSCode when using .NET Interactive
Is this package compatible with Exchange Online?
Please complete the following:
Which version of .NET Interactive are you using? There are a few ways to find this out:
- In a notebook, run the
#!aboutmagic command. - At the command line, run
dotnet interactive --version.
Version: 1.0.235701+3881a96164de75fca84f5f11027f3606b7878044 Build date: 2021-07-09T01:12:29.8185285Z
- OS
- [X] Windows 10
- [ ] macOS
- [ ] Linux (Please specify distro)
- [ ] iOS
- [ ] Android
- Browser
- [X] Chrome
- [ ] Edge
- [ ] Firefox
- [ ] Safari
- Frontend
- [X] Jupyter Notebook
- [ ] Jupyter Lab
- [ ] nteract
- [X] Visual Studio Code
- [ ] Visual Studio Code Insiders
- [ ] Other (please specify)
Screenshots
If applicable, add screenshots to help explain your problem.

@daxian-dbw Any ideas on this one?
I am able to use this command successfully in the windows powershell console; the error is only thrown in Jupyter and in VSCode when using .NET Interactive
@vijaidial By "windows powershell cosnole", do you mean Windows PowerShell 5.1? Can you try using this command in PowerShell 7.1.3, and see if it works?
I remember seeing compatbility issues with ExchangeOnlineManagement in PowerShell Core, so I'm not sure if this module is truely compatible with powershell 7.1.x. @joeyaiello can you please chime in?