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

WIndows execution policy not mentioned in docs #22256

Closed
JordanSDAllen opened this issue Nov 30, 2021 · 3 comments
Closed

WIndows execution policy not mentioned in docs #22256

JordanSDAllen opened this issue Nov 30, 2021 · 3 comments

Comments

@JordanSDAllen
Copy link

@JordanSDAllen JordanSDAllen commented Nov 30, 2021

Description

I had an issue with running the ng server Powershell script on Windows and it should be mentioned in the docs for new users.

What is the affected URL?

No response

Please provide the steps to reproduce the issue

type ng serve on a fresh windows install

Please provide the expected behavior vs the actual behavior you encountered

Expected behaviour is that its allowed to run whereas for me it did not

Please provide a screenshot if possible

Screenshot 2021-11-30 161900

Please provide the exception or error you saw

ng : File C:\Users\jorda\AppData\Roaming\npm\ng.ps1 cannot be loaded because running scripts is disabled on this system. For more information, see 
about_Execution_Policies at https:/go.microsoft.com/fwlink/?LinkID=135170.
At line:1 char:1
+ ng serve
+ ~~
    + CategoryInfo          : SecurityError: (:) [], PSSecurityException
    + FullyQualifiedErrorId : UnauthorizedAccess

Is this a browser-specific issue? If so, please specify the device, browser, and version.

na
@gkalpak gkalpak transferred this issue from angular/angular Nov 30, 2021
@alan-agius4
Copy link
Collaborator

@alan-agius4 alan-agius4 commented Nov 30, 2021

This is standard behaviour for NPM executables, and hence I don’t think it warrants to be included in our docs.

In general on windows it’s recommended that development mode is enabled. https://docs.microsoft.com/en-us/windows/apps/get-started/enable-your-device-for-development

Let’s reconsider this in the future, if we see more users are encountering this issue.

@bitshiftnetau
Copy link

@bitshiftnetau bitshiftnetau commented Dec 2, 2021

I can see what you mean @alan-agius4 but it seems to be something you have to be in the know about and costs nothing to put that in the Angular docs. There are many projects that highlight the need to run with elevated permissions, this doesn't appear to be any different.

If we are really about making Angular user-friendly and approachable for new developers, then commenting on some obvious gotchas would be useful. I just can't see any value in wasting ppl's time on something so obvious, when the answer could easily be shared on a project basis without having the expectation of diving into the arguable difficult to digest world of Microsoft Docs. Which, it should be noted, doesn't provide this answer and there are at least 5 or 6 possible solutions offered in SO for example.

@angular-automatic-lock-bot
Copy link

@angular-automatic-lock-bot angular-automatic-lock-bot bot commented Jan 2, 2022

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Jan 2, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants