Title: `Set-Location` breaks `$PWD` · Issue #9293 · PowerShell/PowerShell · GitHub
Open Graph Title: `Set-Location` breaks `$PWD` · Issue #9293 · PowerShell/PowerShell
X Title: `Set-Location` breaks `$PWD` · Issue #9293 · PowerShell/PowerShell
Description: Steps to reproduce Steps documented below. $PWD.Path populates, but other members break (returning $null). This behavior does not happen by using Set-Location without piping. Expected behavior $ > Set-Location -Path C:\ $ > $PWD.Drive Na...
Open Graph Description: Steps to reproduce Steps documented below. $PWD.Path populates, but other members break (returning $null). This behavior does not happen by using Set-Location without piping. Expected behavior $ > ...
X Description: Steps to reproduce Steps documented below. $PWD.Path populates, but other members break (returning $null). This behavior does not happen by using Set-Location without piping. Expected behavior $ &g...
Opengraph URL: https://github.com/PowerShell/PowerShell/issues/9293
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"`Set-Location` breaks `$PWD`","articleBody":"# Steps to reproduce\r\n\r\nSteps documented below. `$PWD.Path` populates, but other members break (returning `$null`). This behavior does not happen by using `Set-Location` without piping.\r\n\r\n# Expected behavior\r\n\r\n```powershell\r\n$ > Set-Location -Path C:\\\r\n$ > $PWD.Drive\r\n\r\nName Used (GB) Free (GB) Provider Root\r\n---- --------- --------- -------- ----\r\nC 50.00 100.00 FileSystem C:\\\r\n\r\n$ > Get-Item -Path C:\\Windows | Set-Location\r\n$ > $PWD.Drive\r\n\r\nName Used (GB) Free (GB) Provider Root\r\n---- --------- --------- -------- ----\r\nC 50.00 100.00 FileSystem C:\\\r\n\r\n$ >\r\n```\r\n\r\n# Actual behavior\r\n\r\n```powershell\r\n$ > Set-Location -Path C:\\\r\n$ > $PWD.Drive\r\n\r\nName Used (GB) Free (GB) Provider Root\r\n---- --------- --------- -------- ----\r\nC 50.00 100.00 FileSystem C:\\\r\n\r\n$ > Get-Item -Path C:\\Windows | Set-Location\r\n$ > $PWD.Drive\r\n$ >\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 6.2.0\r\nPSEdition Core\r\nGitCommitId 6.2.0\r\nOS Microsoft Windows 6.1.7601 S\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/morsley","@type":"Person","name":"morsley"},"datePublished":"2019-04-04T16:51:54Z","url":"https://github.com/PowerShell/PowerShell/issues/9293"}
| 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:d1de06f4-3c7a-671f-28eb-c5aca86d807e |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | B3EA:2014BA:E9FE32:14E27B9:6AFDA38D |
| html-safe-nonce | b02bd358736f60e3d0f332f9da0646b6105e8f33e533e70a95979588b436dadd |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCM0VBOjIwMTRCQTpFOUZFMzI6MTRFMjdCOTo2QUZEQTM4RCIsInZpc2l0b3JfaWQiOiIyODc3Njk5NDAyNzI3MTg3MzQiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | d4c401d9cf68ac8cd1c1221d0cb3fcc8e3ff87cdb8849fa7c5e1db15bc808913 |
| hovercard-subject-tag | issue:429383015 |
| 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/9293/issue_layout |
| twitter:image | https://opengraph.githubassets.com/301bd87fa48b01339896e3d2f11b4a16a5e3a1661efb165d869c219d992a776d/PowerShell/PowerShell/issues/9293 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/301bd87fa48b01339896e3d2f11b4a16a5e3a1661efb165d869c219d992a776d/PowerShell/PowerShell/issues/9293 |
| og:image:alt | Steps to reproduce Steps documented below. $PWD.Path populates, but other members break (returning $null). This behavior does not happen by using Set-Location without piping. Expected behavior $ > ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | morsley |
| hostname | github.com |
| expected-hostname | github.com |
| None | bc86424ef34a73b386237872800e922d149d65ba907f63d6f150a2dcb8433bea |
| 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 | 0ddf53eb35c87f1f8df13dbf75c3bdadbfc6e969 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width