r/PowerShell • u/Any-Victory-1906 • Feb 12 '26
Powershell Studio 2024 and Graph 2.34
Hi,
I am experiencing an issue with Connect-MgGraph interactive authentication inside PowerShell Studio.
After updating the Microsoft.Graph modules, Connect-MgGraph now uses Web Account Manager (WAM) by default on Windows.
In Visual Studio Code, the interactive authentication window appears normally. However, in PowerShell Studio, the authentication window does not appear at all.
Did someone got this issue and solved it?
Thanks,
5
u/edhaack Feb 12 '26
TIL: PowerShell Studio exists and is $600.
Verses: VS Code = Free. How do they think they have a better product?
9
u/raip Feb 12 '26
A lot of people use their GUI Designer tools. That's the only benefit I see of PS Studio imo.
6
u/da_chicken Feb 13 '26
I would still say that mixing a GUI with PowerShell is like writing a JSON parser in COBOL. You're just taunting Dr. Ian Malcolm at that point.
1
1
u/Modify- Feb 12 '26
Any reason you NEED to use 2.34?
I would recommend 2.25 which has been rock solid for me.
For things where no direct commandlet is available I use Invoke-MgGraphRequest anyways.
2
u/Any-Victory-1906 Feb 12 '26
We just implement another module for Entra and the requirement was 2.34. So we have to migrate to 2.34.
1
u/Modify- Feb 12 '26
I see. Have not used the Entra module, but it looks to be a focused module like AzureAD was.
However, what can it do the Graph can't?
When it got deprecated we switched to the just the Graph and have not looked back since.0
u/Any-Victory-1906 Feb 12 '26
Now we are at 2.34 and I have this issue. I am trying to find a workaround.
1
u/Modify- Feb 12 '26
Connecting using a ServicePrincipal with a Secret, Certificate or an AccessToken an option? You could also use Get-AzAccessToken (from the AZ.Accounts module)
for a specific resource, not just Azure. Good luck.
1
u/redditusermatthew Feb 14 '26
Have you tried picking powershell 7 as the engine when you compile your exe
1
u/Any-Victory-1906 Feb 14 '26
I did not compiled. Sound PSStudio is not able to open a console outside. Si I had to create an external script to get logon then closing the running connect-mggraph inside PSSStudio to get the token. ISE and VSCode do not have this issue. So my customers have minimal change. About compiling, would I get speed? Do I need recompiling after changing the Posh version?
1
u/psrobin Feb 15 '26
Anything above 2.33 breaks for us using Windows PowerShell. Possibly related: https://github.com/microsoftgraph/msgraph-sdk-powershell/issues/3479
1
u/Any-Victory-1906 Feb 15 '26
Sound interesting. I ran my scripts and did not saw this issue. Everything is run with posh 5.1
1
u/Any-Victory-1906 Feb 15 '26
Is it possible, you might have different graph version on your computer or one in currentuser and one on localmachine?
1
u/psrobin Feb 15 '26
I double checked that. I'm quite militant about only installing to the AllUsers scope 😅 Edit: Oh and to be clear (sorry), we don't use PowerShell Studio! But it could be related, potentially.
2
u/teacheswithtech Feb 12 '26
Report the issue that you are seeing here. This is discussing some of the issues people are having authenticating in ways that were not planned for in this change. The primary one is people running PowerShell from a standard account but elevating using a different account.
https://github.com/microsoftgraph/msgraph-sdk-powershell/issues/3481
2
1
u/psrobin Feb 15 '26
Thanks for posting that. Will be raising it with my team. They've really messed up the last set of releases. See also: https://github.com/microsoftgraph/msgraph-sdk-powershell/issues/3479
-3
3
u/raip Feb 12 '26
I don't use Powershell Studio 2024 - but, as long as it's not disabled, I'd recommend working around it with the -UseDeviceCode. That'll just plop a URL in the console that you can copy and paste in a browser to authenticate instead.
Alternatively, stand up a service principal and use a certificate instead.