Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cake.Powershell possibly broken under Dotnet 6 #93

Open
paulmilbank opened this issue Apr 8, 2022 · 1 comment
Open

Cake.Powershell possibly broken under Dotnet 6 #93

paulmilbank opened this issue Apr 8, 2022 · 1 comment

Comments

@paulmilbank
Copy link

paulmilbank commented Apr 8, 2022

assembly 'Cake.Powershell, Version=1.0.1.0, Culture=neutral, PublicKeyToken=null' 

is referencing an older version of Cake.Core (1.0.0). 

For best compatibility it should target Cake.Core version 2.0.0.

Could not load D:\jenkins\workspace\Pushpay_Pushpay_PR-26486\tools\Addins\Cake.Powershell.1.0.1\lib\net5.0\Cake.Powershell.dll (missing System.Management.Automation, Version=7.1.2.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35)

powershell.exe : D:/jenkins/workspace/Pushpay_Pushpay_PR-26486/build.cake(78,5): error CS0103: The name 'StartPowershellFile' does not exist in the current context

At D:\jenkins\workspace\Pushpay_Pushpay_PR-26486@tmp\durable-625b7f48\powershellWrapper.ps1:3 char:1

I am also running into issues getting this going on a Mac locally. The Mac has Dotnet 6 installed too so my understanding is it will be trying to run under that runtime. My Mac has Powershell installed. I am running the build.ps1 bootstrap script under Powershell on the Mac.

./build.ps1 --target "Frontend Build"
Restore was successful.
Restore was successful.
Error: Failed to install addin 'Cake.Powershell'.

Running the 2.1.0 version of Cakebuild and the 1.01 version of the Cake.Powershell plugin.
The Build agent is running Server 2019 with VS2019 and VS2022 build tools. It will be running dotnet 6 when installing Cake tools and running the build script.

Please let me know if you need other info, I'm happy to provide further logs or answer questions to help get this resolved.

@paulmilbank
Copy link
Author

paulmilbank commented Apr 8, 2022

The

assembly 'Cake.Powershell, Version=1.0.1.0, Culture=neutral, PublicKeyToken=null' 

is referencing an older version of Cake.Core (1.0.0). 

For best compatibility it should target Cake.Core version 2.0.0.

Seems to be a warning more than anything as the Yarn plugin has the same error but works fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant