r/PowerShell • MVP, Community Blogger • Oct 05 '26

News Microsoft Graph PowerShell SDK V2.41 Finally Fixes Assembly Clash

The Microsoft Graph PowerShell SDK has long been plagued by assembly clashes that meant it couldn’t be used in the same session as other Microsoft 365 modules. After Microsoft engineering groups looked at the problem for 18 months, a solution was found by MVP Stephen van Rooij and is now available in V2.41. Apart from an issue with old PowerShell V7 versions (which affects Azure Automation runtime environments), the fix looks solid and the SDK can once again be loaded into PowerShell sessions alongside the Exchange Online and Teams modules.

https://office365itpros.com/2026/10/05/microsoft-graph-powershell-sdk-fix/

50 Upvotes

18 comments sorted by

View all comments

Show parent comment

6

u/Subject_Meal_2683 Oct 05 '26

Performance (and dependency) wise making the api calls yourself using Invoke-Restmethod is much better. When I was writing a lot of scripts which depended on Graph I dropped the Graph module dependency because it was so slow compared to scripts where I did most of the heavy lifting myself. Of course, on small tenants it doesn't make a huge difference but since I also work with tenants that have over 100k users every millisecond I win is a lot.

(And of course, the tradeoff is having to do more of the heavy lifting myself, anti throttling code, retry logic... so it's the tradeoff between "easy" and "robust and performance")

1

u/Federal_Ad2455 Oct 05 '26

Without using graph api json batching you are just half way there 🙂 for large tenant it is a must

1

u/Andrew-Powershell Oct 05 '26

Anyone that I know who regularly uses graph just calls the API themselves.

2

u/Flettys Oct 05 '26

The most common pattern I see is using only Connect-MgGraph and Invoke-MgGraphRequest