blocked by software Restriction policies?

Asked

Viewed 394 times

2

Someone has come across this message when opening Visual Sdudio??

\Packages Entityframework.5.0.0 tools init.ps1 cannot be Loaded because its Operation is blocked by software Restriction policies, such as those created by using Group Policy. At line:1 char:45 + $__pc_args=@(); $input|%{$__pc_args+=$_}; & ’D: Fonts Particular Projects Vis ... + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + Categoryinfo : Securityerror: (:) [], Pssecurityexception + Fullyqualifiederrorid : Unauthorizedaccess

Could help me solve this?

  • When opening a project? Or even without any project it gives this error? Have you tried running VS as an administrator?

  • Yes when opening a project... Anyone. And I have already automatically opened as VS @jbueno Adm

  • 1

    Already changed the execution policy in the power shell?

  • I executed the PM> Unrestricted Set-Executionpolicy command and is not giving error anymore.

2 answers

2


In the Package Manager Console, type the following:

PM> Set-ExecutionPolicy Unrestricted

There are no problems in reducing the script constraint policy on a development machine.

If it doesn’t work first, try running Visual Studio as an administrator and try again.

Also, if it is not a project constraint, it is even better to update the Entity Framework. Version 6 does not have this constraint.

  • need to do this always!?

  • No. Pro Entity Framework 6 I never had to do.

  • Well... Anything but, I run the command again. VLWS @Gypsy.

0

In my case this problem occurred because there was a Microsoft certificate with problem. To resolve go to Internet Options => Content => Certificates in the Untrusted Publishers tab and remove Microsoft Corporation. https://github.com/NuGet/Home/issues/7158

Browser other questions tagged

You are not signed in. Login or sign up in order to post.