Reputation: 23
I bought the book "Learn Python Programming, 4th Edition", and started the installation process. Python 3.12.8 downloaded and installed OK on my WINDOWS 10 PC.
Now the tricky bit which I cannot get past: The book says do everything in a powershell, which I'm happy with, and follow the instructions to make a dir "proj_01" and then run the command: py 3.12 -m venv lpp4ed which creates the lpp4ed sub-dir and adds scripts etc.
Then I get to the bit that does not work:
The command .\lpp4ed\Scripts\activate sets off a windows warning message about scripts being disabled and cannot load the "activate.ps1" script
However, the command .\lpp4ed\Scripts\activate.bat does not set off the warning, but I have no idea if it has done anything or not.
Any help much appreciated
Getting nowhere. I need help to sort this out, I want to learn how to do all this stuff properly but haven't got past the first simple hurdle, very frustrating!
It seems to be something to do with Execution Policy, but changing that seems fraught with danger!
Upvotes: 1
Views: 51
Reputation: 833
Try copy-paste and run this in Powershell:
Set-ExecutionPolicy -Scope CurrentUser -ExecutionPolicy Unrestricted
Upvotes: 0