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
Yet, since 3.5.0, two functions have declared parameters using the [ushort] type, which does not exist in the .NET Framework, causing both functions to fail under Windows PowerShell with the "unable to find type [ushort]" error. The issue still exists in 3.6.0.
This is not an issue under PowerShell (as distinct from Windows PowerShell) where an additional library declares the ushort type (system.private.corelib).
Example from New-DkimSigningConfig showing inappropriate ushort declaration for KeySize parameter:
That the commands declare the "KeySize" parameter using either [uint16] (if for some reason it must be a 16-bit value) or - in line with the rest of the module's functions - [uint32] (which to my mind would be more consistent).This would resolve the type exception while maintaining compatibility on Windows PowerShell.
Actual behavior
Under Windows PowerShell, calls to both New-DkimSigningConfig and Rotate-DkimSigningConfig fail immediately (before function entry) on account of the ushort type not existing, as shown in the screenshot.
Error details
Unable to find type [ushort].At C:\Users\lain.robertson\AppData\Local\Temp\tmpEXO_faj3kift.kut\tmpEXO_faj3kift.kut.psm1:25026 char:5+ [ushort]+ ~~~~~~~~ + CategoryInfo : InvalidOperation: (ushort:TypeName) [], RuntimeException + FullyQualifiedErrorId : TypeNotFound
Hi, I'm equally affected, and confirm that it doesn't seem to be only 3.6.0 but also 3.5.1, however it the could be that the command is remotely loaded from ExO backend servers so the version of the installed module might not even matter:
>$PSVersionTable
Name Value
---------
PSVersion 5.1.22621.3958
PSEdition Desktop
PSCompatibleVersions {1.0,2.0,3.0,4.0...}
BuildVersion 10.0.22621.3958
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1>Get-Command Rotate-DkimSigningConfig
CommandType Name Version Source
----------------------------FunctionRotate-DkimSigningConfig 1.0 tmpEXO_bwryafqj.uzx
However I don't think this bug report will get noticed, since Microsoft requires to report issues to release versions via support tickets as documented here.
Prerequisites
Steps to reproduce
According to the documentation, for the ExchangeOnlineManagement module:
"All versions of the module are supported in Windows PowerShell 5.1."
Yet, since 3.5.0, two functions have declared parameters using the [ushort] type, which does not exist in the .NET Framework, causing both functions to fail under Windows PowerShell with the "unable to find type [ushort]" error. The issue still exists in 3.6.0.
This is not an issue under PowerShell (as distinct from Windows PowerShell) where an additional library declares the ushort type (system.private.corelib).
Example from New-DkimSigningConfig showing inappropriate ushort declaration for KeySize parameter:
`function script:New-DkimSigningConfig
{
[CmdletBinding(SupportsShouldProcess=$true, ConfirmImpact='Medium')]
param(
`
Expected behavior
Actual behavior
Under Windows PowerShell, calls to both New-DkimSigningConfig and Rotate-DkimSigningConfig fail immediately (before function entry) on account of the ushort type not existing, as shown in the screenshot.
Error details
Environment data
Version
3.6.0
Visuals
The text was updated successfully, but these errors were encountered: