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
We are using Export-M365DSCConfiguration to dump the configuration in git and track changes between exports. Because the order of the Teams objects are changing in every export git will report file changes.
The reason for this behavior is because Get-Teams seems to return the objects in random order.
$first = Get-Team
$second = Get-Team
# Will return differences
Compare-Object $first.GroupId $second.GroupId -SyncWindow 0
$first = Get-Team | Sort-Object GroupId
$second = Get-Team | Sort-Object GroupId
# Will not return any differences
Compare-Object $first.GroupId $second.GroupId -SyncWindow 0
It would be great if the Teams resources would keep the order (for example by sorting by GroupId). The following resources are affected:
TeamsTeam
TeamsChannel
TeamsUser
TeamsChannelTab
For all other resources we backup the order seems to be OK between exports.
If you agree, I could create a pull request to change the behavior for these resources
Microsoft 365 DSC Version
DEV / V1.25.219.2
Which workloads are affected
Teams
The DSC configuration
Verbose logs showing the problem
Environment Information + PowerShell Version
The text was updated successfully, but these errors were encountered:
Description of the issue
We are using
Export-M365DSCConfiguration
to dump the configuration in git and track changes between exports. Because the order of the Teams objects are changing in every export git will report file changes.The reason for this behavior is because
Get-Teams
seems to return the objects in random order.It would be great if the Teams resources would keep the order (for example by sorting by GroupId). The following resources are affected:
For all other resources we backup the order seems to be OK between exports.
If you agree, I could create a pull request to change the behavior for these resources
Microsoft 365 DSC Version
DEV / V1.25.219.2
Which workloads are affected
Teams
The DSC configuration
Verbose logs showing the problem
Environment Information + PowerShell Version
The text was updated successfully, but these errors were encountered: