Title: `Get-Service` | Empty fields dedicated to error messages · Issue #20187 · PowerShell/PowerShell · GitHub
Open Graph Title: `Get-Service` | Empty fields dedicated to error messages · Issue #20187 · PowerShell/PowerShell
X Title: `Get-Service` | Empty fields dedicated to error messages · Issue #20187 · PowerShell/PowerShell
Description: Prerequisites Write a descriptive title. Make sure you are able to repro it on the latest released version Search the existing issues. Refer to the FAQ. Refer to Differences between Windows PowerShell 5.1 and PowerShell. Steps to reprodu...
Open Graph Description: Prerequisites Write a descriptive title. Make sure you are able to repro it on the latest released version Search the existing issues. Refer to the FAQ. Refer to Differences between Windows PowerSh...
X Description: Prerequisites Write a descriptive title. Make sure you are able to repro it on the latest released version Search the existing issues. Refer to the FAQ. Refer to Differences between Windows PowerSh...
Opengraph URL: https://github.com/PowerShell/PowerShell/issues/20187
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"`Get-Service` | Empty fields dedicated to error messages","articleBody":"### Prerequisites\r\n\r\n- [X] Write a descriptive title.\r\n- [X] Make sure you are able to repro it on the [latest released version](https://github.com/PowerShell/PowerShell/releases)\r\n- [X] Search the existing issues.\r\n- [X] Refer to the [FAQ](https://github.com/PowerShell/PowerShell/blob/master/docs/FAQ.md).\r\n- [X] Refer to [Differences between Windows PowerShell 5.1 and PowerShell](https://learn.microsoft.com/powershell/scripting/whats-new/differences-from-windows-powershell).\r\n\r\n### Steps to reproduce\r\n\r\n```powershell\r\nGet-Service | Where-Object {$_.Status -eq \"running\"} | Format-Table -AutoSize -Property Name,DisplayName\r\n```\r\n\r\n### Expected behavior\r\n\r\n```console\r\nNon-empty fields dedicated to error messages.\r\n```\r\n\r\n\r\n### Actual behavior\r\n\r\n```console\r\nEmpty fields dedicated to error messages. As part of the output:\r\n\r\n\r\nGet-Service: Service 'McpManagementService (McpManagementService)' cannot be queried due to the following error:\r\nGet-Service: Service 'NPSMSvc_329b6 (NPSMSvc_329b6)' cannot be queried due to the following error:\r\n```\r\n\r\n\r\n### Error details\r\n\r\n```console\r\nException :\r\n Type : Microsoft.PowerShell.Commands.ServiceCommandException\r\n ServiceName : NPSMSvc_329b6\r\n Message : Service 'NPSMSvc_329b6 (NPSMSvc_329b6)' cannot be queried due to the following error:\r\n HResult : -2146233087\r\nTargetObject : System.ServiceProcess.ServiceController\r\nCategoryInfo : PermissionDenied: (System.ServiceProcess.ServiceController:ServiceController) [Get-Ser\r\nvice], ServiceCommandException\r\nFullyQualifiedErrorId : CouldNotGetServiceInfo,Microsoft.PowerShell.Commands.GetServiceCommand\r\nInvocationInfo :\r\n MyCommand : Get-Service\r\n ScriptLineNumber : 1\r\n OffsetInLine : 1\r\n HistoryId : 1\r\n Line : Get-Service | Where-Object {$_.Status -eq \"running\"} | Format-Table -AutoSize -Property\r\n Name,DisplayName\r\n Statement : Get-Service\r\n PositionMessage : At line:1 char:1\r\n + Get-Service | Where-Object {$_.Status -eq \"running\"} | Format-Table - …\r\n + ~~~~~~~~~~~\r\n InvocationName : Get-Service\r\n CommandOrigin : Internal\r\nScriptStackTrace : at \u003cScriptBlock\u003e, \u003cNo file\u003e: line 1\r\nPipelineIterationInfo :\r\n```\r\n\r\n\r\n### Environment data\r\n\r\n```powershell\r\nPSVersion 7.4.0-preview.5\r\nPSEdition Core\r\nGitCommitId 7.4.0-preview.5\r\nOS Microsoft Windows 10.0.22000\r\nPlatform Win32NT\r\nPSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}\r\nPSRemotingProtocolVersion 2.3\r\nSerializationVersion 1.1.0.1\r\nWSManStackVersion 3.0\r\n```\r\n\r\n\r\n### Visuals\r\n\r\n_","author":{"url":"https://github.com/Ricky-Tigg","@type":"Person","name":"Ricky-Tigg"},"datePublished":"2023-08-30T11:56:01.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":6},"url":"https://github.com/20187/PowerShell/issues/20187"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:bed49310-06e5-29f2-7192-af6b75eb1001 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | ABCC:206F88:201ECE7:2B180E9:6A546330 |
| html-safe-nonce | aa07350b9fba5a01f5a49f5369ea5925b2cbfe194ea925df77524fded786184f |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBQkNDOjIwNkY4ODoyMDFFQ0U3OjJCMTgwRTk6NkE1NDYzMzAiLCJ2aXNpdG9yX2lkIjoiNTA3MDc3NjQ0Nzc0NTY0NjU2IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 5e72b81c6c9e10f8d20894c145e6f121f43061d3f184ae90a257a91a43a95f8b |
| hovercard-subject-tag | issue:1873524500 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/PowerShell/PowerShell/20187/issue_layout |
| twitter:image | https://opengraph.githubassets.com/f2f79d28c69e95cdf6786361aa0aace4160aa2dcc085675da1fc2ca1110b09fc/PowerShell/PowerShell/issues/20187 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/f2f79d28c69e95cdf6786361aa0aace4160aa2dcc085675da1fc2ca1110b09fc/PowerShell/PowerShell/issues/20187 |
| og:image:alt | Prerequisites Write a descriptive title. Make sure you are able to repro it on the latest released version Search the existing issues. Refer to the FAQ. Refer to Differences between Windows PowerSh... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | Ricky-Tigg |
| hostname | github.com |
| expected-hostname | github.com |
| None | b9a586c06a05a7a86fc7e3f4dbd03e42f6869085879aa184aa6369456dbd50fb |
| turbo-cache-control | no-preview |
| go-import | github.com/PowerShell/PowerShell git https://github.com/PowerShell/PowerShell.git |
| octolytics-dimension-user_id | 11524380 |
| octolytics-dimension-user_login | PowerShell |
| octolytics-dimension-repository_id | 49609581 |
| octolytics-dimension-repository_nwo | PowerShell/PowerShell |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 49609581 |
| octolytics-dimension-repository_network_root_nwo | PowerShell/PowerShell |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 6d28624802c2f7d9500239dd6870ed7031b7353b |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width