Title: Return casesensitive hashtable with Group-Object · Issue #10441 · PowerShell/PowerShell · GitHub
Open Graph Title: Return casesensitive hashtable with Group-Object · Issue #10441 · PowerShell/PowerShell
X Title: Return casesensitive hashtable with Group-Object · Issue #10441 · PowerShell/PowerShell
Description: Steps to reproduce I know PowerShell is mostly case insensitive, but when using both -AsHashTable and -CaseSensitive I expected to end up with a case sensitive hashtable. $capitonyms = @( [PSCustomObject]@{ Capitonym = 'Bill' } [PSCustom...
Open Graph Description: Steps to reproduce I know PowerShell is mostly case insensitive, but when using both -AsHashTable and -CaseSensitive I expected to end up with a case sensitive hashtable. $capitonyms = @( [PSCustom...
X Description: Steps to reproduce I know PowerShell is mostly case insensitive, but when using both -AsHashTable and -CaseSensitive I expected to end up with a case sensitive hashtable. $capitonyms = @( [PSCustom...
Opengraph URL: https://github.com/PowerShell/PowerShell/issues/10441
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Return casesensitive hashtable with Group-Object","articleBody":"\u003c!--\r\n\r\nFor Windows PowerShell 5.1 issues, suggestions, or feature requests please use the following link instead:\r\nWindows PowerShell [UserVoice](https://windowsserver.uservoice.com/forums/301869-powershell)\r\n\r\nThis repository is **ONLY** for PowerShell Core 6 issues.\r\n\r\n- Make sure you are able to repro it on the [latest released version](https://github.com/PowerShell/PowerShell/releases)\r\n- Search the existing issues.\r\n- Refer to the [FAQ](https://github.com/PowerShell/PowerShell/blob/master/docs/FAQ.md).\r\n- Refer to the [known issues](https://docs.microsoft.com/powershell/scripting/whats-new/known-issues-ps6?view=powershell-6).\r\n\r\n-->\r\n\r\n# Steps to reproduce\r\nI know PowerShell is mostly case insensitive, but when using both `-AsHashTable` and `-CaseSensitive` I expected to end up with a case sensitive hashtable.\r\n```powershell\r\n$capitonyms = @(\r\n [PSCustomObject]@{\r\n Capitonym = 'Bill'\r\n }\r\n [PSCustomObject]@{\r\n Capitonym = 'bill'\r\n }\r\n)\r\n\r\n$capitonyms | Group-Object Capitonym -AsHashTable -CaseSensitive\r\n```\r\n\r\n# Expected behavior\r\n\r\n```none\r\nName Value\r\n---- -----\r\nBill {@{Capitonym=Bill}}\r\nbill {@{Capitonym=bill}}\r\n```\r\n\r\n# Actual behavior\r\n\r\n```none\r\nGroup-Object : The objects grouped by this property cannot be expanded because there is a key duplication. Provide a valid value for the property, and then try again.\r\nAt line:1 char:15\r\n+ $capitonyms | Group-Object Capitonym -AsHashTable -CaseSensitive\r\n+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\r\n+ CategoryInfo : InvalidArgument: (:) [Group-Object], Exception\r\n+ FullyQualifiedErrorId : The objects grouped by this property cannot be expanded because there is a key duplication. Provide a valid value for the property, and then try again.,Microsoft.PowerShell.Commands.GroupObjectCommand\r\n```\r\n\r\n# Environment data\r\n\r\n\u003c!-- provide the output of $PSVersionTable -->\r\n\r\n```none\r\nName Value\r\n---- -----\r\nPSVersion 7.0.0-preview.3\r\nPSEdition Core\r\nGitCommitId 7.0.0-preview.3\r\nOS Microsoft Windows 10.0.18362\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","author":{"url":"https://github.com/lahell","@type":"Person","name":"lahell"},"datePublished":"2019-08-24T10:38:28Z","url":"https://github.com/PowerShell/PowerShell/issues/10441"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| 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:a4923593-6d4b-3469-8b89-68970fa136fc |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | E594:1A631D:6861F:8DE11:6AFD48CD |
| html-safe-nonce | b85751a516ca7dd998d7d7f7e7f754b6b3bb358d2f6b051a8a8ffb90da0e4b0d |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFNTk0OjFBNjMxRDo2ODYxRjo4REUxMTo2QUZENDhDRCIsInZpc2l0b3JfaWQiOiIyNzk3NDI5NzMzNDU5ODM5MTgxIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | ba4b32f9e26d40d8e5e92635885b3dcd431d76ac2d5c1e1f98674ae66db1e84d |
| hovercard-subject-tag | issue:484803839 |
| 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/10441/issue_layout |
| twitter:image | https://opengraph.githubassets.com/6c9bb196d3474da2f61188211cbab641a626bfbeb255df649f271b3a7f7f8115/PowerShell/PowerShell/issues/10441 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/6c9bb196d3474da2f61188211cbab641a626bfbeb255df649f271b3a7f7f8115/PowerShell/PowerShell/issues/10441 |
| og:image:alt | Steps to reproduce I know PowerShell is mostly case insensitive, but when using both -AsHashTable and -CaseSensitive I expected to end up with a case sensitive hashtable. $capitonyms = @( [PSCustom... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | lahell |
| hostname | github.com |
| expected-hostname | github.com |
| None | bdbacc25b921224ff0befcb9e629560a1255be51aec9991d6e3f95b5e9151474 |
| 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 | 556dd37bb0aceffb25724e151b5d858b3265b40b |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width