René's URL Explorer Experiment


Title: Question: not getting expected results for get-formatdata · Issue #9300 · PowerShell/PowerShell · GitHub

Open Graph Title: Question: not getting expected results for get-formatdata · Issue #9300 · PowerShell/PowerShell

X Title: Question: not getting expected results for get-formatdata · Issue #9300 · PowerShell/PowerShell

Description: This is a followup to issue #8063 which appears closed but which did not fix the originally reported problem. Steps to reproduce Hi Steve, I have been anxiously awaiting this fix to test out the issues we discussed last year. Unfortunate...

Open Graph Description: This is a followup to issue #8063 which appears closed but which did not fix the originally reported problem. Steps to reproduce Hi Steve, I have been anxiously awaiting this fix to test out the is...

X Description: This is a followup to issue #8063 which appears closed but which did not fix the originally reported problem. Steps to reproduce Hi Steve, I have been anxiously awaiting this fix to test out the is...

Opengraph URL: https://github.com/PowerShell/PowerShell/issues/9300

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Question: not getting expected results for get-formatdata","articleBody":"This is a followup to issue #8063 which appears closed but which did not fix the originally reported problem.\r\n\r\n# Steps to reproduce\r\n\r\nHi Steve,\r\n\r\nI have been anxiously awaiting this fix to test out the issues we discussed last year.\r\n\r\nUnfortunately the problems do not appear to be fixed and things appear to be seriously broken still to the point that the results are unusable.\r\n\r\nRun these commands\r\n\r\npwsh -noprofile\r\nGet-FormatData -PowerShellVersion 6.2 -TypeName System.IO.DirectoryInfo | Export-FormatData -LiteralPath DirectoryInfo.ps1xml\r\nGet-FormatData -PowerShellVersion 6.2 -TypeName System.IO.FileInfo      | Export-FormatData -LiteralPath FileInfo.ps1xml\r\nIf you compare DirectoryInfo.ps1xml and FileInfo.ps1xml you will find the are exactly the same, however, the output for a directory item versus a file item should not be the same as a directory does not contain a length.\r\n\r\nIgnoring that issue, the results returned are missing lots of XML code that was previously in FileSystem.format.ps1xml.\r\n\r\nI won't detail them all here as you can compare the results produced of Get-FormatData with the old FileSystem.format.ps1xml file to see them all, however, I will point out a few.\r\n\r\nFileSystem.format.ps1xml created a SelectionSet named FileSystemTypes and then used that and a CustomControlName FileSystemTypes-GroupingFormat for the view definitions. Those are all missing from the \"Get-FormatData\" results for System.IO.DirectoryInfo / System.IO.FileInfo.\r\n\r\nIgnore those issues, I attempted to merge my changes into the results returned from Get-FormatData and I found that my changes were not displaying so I did this simple test.\r\n\r\npwsh -noprofile\r\nGet-FormatData -PowerShellVersion 6.2 -TypeName System.IO.DirectoryInfo | Export-FormatData -LiteralPath DirectoryInfo.ps1xml\r\n\r\nEdit the DirectoryInfo.ps1xml file and make the following change:\r\n\r\n    Look for \u003cLabel>LastWriteTime\u003c/Label> and change it to \u003cLabel>XXXXWriteTime\u003c/Label>\r\n\r\nNow run\r\n\r\n    Update-FormatData -PrependPath .\\DirectoryInfo.ps1xml\r\n\r\nNow run Get-ChildItem and you will see that the label still says LastWriteTime instead of XXXXWriteTime\r\n\r\nNow run this to get what the updated formatting info looks like\r\n\r\n    Get-FormatData -PowerShellVersion 6.2 -TypeName System.IO.DirectoryInfo | Export-FormatData -LiteralPath DirectoryInfo2.ps1xml\r\n\r\nYou will find that it does show the change, however. there is another section after it that still has the label as \"LastWriteTime\".\r\nI believe all of these issues are because Get-FormatData is not returning the full and correct format data for these types.\r\n\r\nIf I run \"Update-FormatData -Prepend My,FileSystem.format.ps1\" which uses the modified version of the old FileSystem.format.ps1xml file that used to be included in PowerShell, then everything works correctly and it has my changes.\r\n\r\nSo we are back to the original problem.\r\n\r\nThere needs to be a way for me to obtain the format data being used (either via a file like it previously did or with Get-FormatData returning the correct formatting that is really being used).\r\n\r\nSince PowerShell is no longer including the *.format.ps1xml files and Get-FormatData is broken and does not return the correct format data I have no way to determine what changes were made in new versions of PowerShell so that I can integrate them into my modified version.\r\n\r\nI hope that this can be made a priority and get fixed soon.\r\n\r\nHoller if you want any more details.\r\n\r\nThanks!\r\n\r\nJoe\r\n","author":{"url":"https://github.com/JoeSalmeri","@type":"Person","name":"JoeSalmeri"},"datePublished":"2019-04-05T19:32:49Z","url":"https://github.com/PowerShell/PowerShell/issues/9300"}

react-profiling0
react-import-mapreact,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-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:6b060e82-4757-f378-1c91-b97e943a2de4
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idBB76:5453:1D2C6D:2993BA:6AFD51CA
html-safe-nonce28fb9b55c547ade15109cf84a9d4e07d01898ec56dfc09c36ec7d347c5d0e44e
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCQjc2OjU0NTM6MUQyQzZEOjI5OTNCQTo2QUZENTFDQSIsInZpc2l0b3JfaWQiOiIzNzc3MTk3NDU4Mjc0OTk2NjgyIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmac3c1d3f03fd7f68c89a0f455a52a6bf0efd291dd9e6035fef5825c5077e9b5882
hovercard-subject-tagissue:429904072
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/PowerShell/PowerShell/9300/issue_layout
twitter:imagehttps://opengraph.githubassets.com/5b0ea9a35344e09cbd423919435f6a5c646b23fdce6d5d2dbc4f90f99200a94b/PowerShell/PowerShell/issues/9300
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/5b0ea9a35344e09cbd423919435f6a5c646b23fdce6d5d2dbc4f90f99200a94b/PowerShell/PowerShell/issues/9300
og:image:altThis is a followup to issue #8063 which appears closed but which did not fix the originally reported problem. Steps to reproduce Hi Steve, I have been anxiously awaiting this fix to test out the is...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernameJoeSalmeri
hostnamegithub.com
expected-hostnamegithub.com
None66653c2e55a6fff2930be1bdf07ee4f8aa137e3956d056c822563be6f878755e
turbo-cache-controlno-preview
go-importgithub.com/PowerShell/PowerShell git https://github.com/PowerShell/PowerShell.git
octolytics-dimension-user_id11524380
octolytics-dimension-user_loginPowerShell
octolytics-dimension-repository_id49609581
octolytics-dimension-repository_nwoPowerShell/PowerShell
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id49609581
octolytics-dimension-repository_network_root_nwoPowerShell/PowerShell
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
releaseb6f01f7cb9f35f8c09949773241a3d49dd04b340
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/PowerShell/PowerShell/issues/9300#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FPowerShell%2FPowerShell%2Fissues%2F9300
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FPowerShell%2FPowerShell%2Fissues%2F9300
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=PowerShell%2FPowerShell
Reloadhttps://github.com/PowerShell/PowerShell/issues/9300
Reloadhttps://github.com/PowerShell/PowerShell/issues/9300
Reloadhttps://github.com/PowerShell/PowerShell/issues/9300
PowerShellhttps://github.com/PowerShell
PowerShellhttps://github.com/PowerShell/PowerShell
Codehttps://github.com/PowerShell/PowerShell
Issues1.3k (1.3k)https://github.com/PowerShell/PowerShell/issues
Pull requests365 (365)https://github.com/PowerShell/PowerShell/pulls
Discussionshttps://github.com/PowerShell/PowerShell/discussions
Actionshttps://github.com/PowerShell/PowerShell/actions
Projectshttps://github.com/PowerShell/PowerShell/projects
Security and quality3 (3)https://github.com/PowerShell/PowerShell/security
Insightshttps://github.com/PowerShell/PowerShell/insights
https://github.com/PowerShell/PowerShell
New issuehttps://github.com/login?return_to=https://github.com/PowerShell/PowerShell/issues/9300
New issuehttps://github.com/login?return_to=https://github.com/PowerShell/PowerShell/issues/9300
Question: not getting expected results for get-formatdatahttps://github.com/PowerShell/PowerShell/issues/9300#top
Issue-BugIssue has been identified as a bug in the producthttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Issue-Bug%22
Resolution-No ActivityIssue has had no activity for 6 months or morehttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Resolution-No%20Activity%22
WG-Cmdletsgeneral cmdlet issueshttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22WG-Cmdlets%22
https://github.com/JoeSalmeri
Joe S (JoeSalmeri)https://github.com/JoeSalmeri
on Apr 5, 2019https://github.com/PowerShell/PowerShell/issues/9300#issue-429904072
#8063https://github.com/PowerShell/PowerShell/pull/8063
Nexthttps://github.com/PowerShell/PowerShell/issues/9300?timeline_page=1
Joe S (JoeSalmeri)https://github.com/JoeSalmeri
Issue-Questionideally support can be provided via other mechanisms, but sometimes folks do open an issue to get ahttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Issue-Question%22
on Apr 5, 2019https://github.com/PowerShell/PowerShell/issues/9300#event-2256740627
https://github.com/TravisEz13
Travis Plunk (TravisEz13)https://github.com/TravisEz13
on Apr 5, 2019https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-480455238
Joe S (@JoeSalmeri)https://github.com/JoeSalmeri
Travis Plunk (TravisEz13)https://github.com/TravisEz13
on Apr 5, 2019https://github.com/PowerShell/PowerShell/issues/9300#event-2257162424
https://github.com/JoeSalmeri
Joe S (JoeSalmeri)https://github.com/JoeSalmeri
on Apr 6, 2019https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-480461461
Travis Plunk (@TravisEz13)https://github.com/TravisEz13
https://github.com/JoeSalmeri
Joe S (JoeSalmeri)https://github.com/JoeSalmeri
on May 28, 2019https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-496324029
Travis Plunk (@TravisEz13)https://github.com/TravisEz13
https://github.com/vexx32
Rain Sallow (/u/ta11ow) (vexx32)https://github.com/vexx32
on May 28, 2019https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-496334024
https://github.com/JoeSalmeri
Joe S (JoeSalmeri)https://github.com/JoeSalmeri
on May 31, 2019https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-497674178
Rain Sallow (/u/ta11ow) (@vexx32)https://github.com/vexx32
https://github.com/vexx32
Rain Sallow (/u/ta11ow) (vexx32)https://github.com/vexx32
on May 31, 2019https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-497674952
https://github.com/JoeSalmeri
Joe S (JoeSalmeri)https://github.com/JoeSalmeri
on Aug 20, 2019https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-523005252
https://github.com/vexx32
Rain Sallow (/u/ta11ow) (vexx32)https://github.com/vexx32
on Aug 20, 2019https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-523007736
https://github.com/JoeSalmeri
Joe S (JoeSalmeri)https://github.com/JoeSalmeri
on Aug 20, 2019https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-523047054
Rain Sallow (/u/ta11ow) (@vexx32)https://github.com/vexx32
https://github.com/marckassay
Marc Kassay (marckassay)https://github.com/marckassay
on Jan 15, 2020https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-574759257
Joe S (@JoeSalmeri)https://github.com/JoeSalmeri
https://github.com/JoeSalmeri
Joe S (JoeSalmeri)https://github.com/JoeSalmeri
on Jan 19, 2020https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-576036629
Marc Kassay (@marckassay)https://github.com/marckassay
Travis Plunk (@TravisEz13)https://github.com/TravisEz13
Travis Plunk (@TravisEz13)https://github.com/TravisEz13
Travis Plunk (@TravisEz13)https://github.com/TravisEz13
Travis Plunk (@TravisEz13)https://github.com/TravisEz13
https://github.com/marckassay
Marc Kassay (marckassay)https://github.com/marckassay
on Jan 22, 2020https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-577252261
Joe S (@JoeSalmeri)https://github.com/JoeSalmeri
https://github.com/JoeSalmeri
Joe S (JoeSalmeri)https://github.com/JoeSalmeri
on Jan 22, 2020https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-577259430
Marc Kassay (@marckassay)https://github.com/marckassay
Ilya (iSazonov)https://github.com/iSazonov
Issue-BugIssue has been identified as a bug in the producthttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Issue-Bug%22
Up-for-GrabsUp-for-grabs issues are not high priorities, and may be opportunities for external contributorshttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Up-for-Grabs%22
on Jan 31, 2020https://github.com/PowerShell/PowerShell/issues/9300#event-2997390434
https://github.com/JoeSalmeri
Joe S (JoeSalmeri)https://github.com/JoeSalmeri
on Nov 11, 2021https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-966698465
Travis Plunk (@TravisEz13)https://github.com/TravisEz13
https://github.com/JoeSalmeri
Joe S (JoeSalmeri)https://github.com/JoeSalmeri
on Nov 12, 2021https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-966735332
https://github.com/iSazonov
Ilya (iSazonov)https://github.com/iSazonov
on Nov 12, 2021https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-966829242
Joe S (@JoeSalmeri)https://github.com/JoeSalmeri
#11596https://github.com/PowerShell/PowerShell/issues/11596
#11308https://github.com/PowerShell/PowerShell/issues/11308
#11307https://github.com/PowerShell/PowerShell/issues/11307
Dongbo Wang (@daxian-dbw)https://github.com/daxian-dbw
Michael Klement (@mklement0)https://github.com/mklement0
https://github.com/JoeSalmeri
Joe S (JoeSalmeri)https://github.com/JoeSalmeri
on Nov 12, 2021https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-967173065
Ilya (@iSazonov)https://github.com/iSazonov
Dongbo Wang (daxian-dbw)https://github.com/daxian-dbw
Up-for-GrabsUp-for-grabs issues are not high priorities, and may be opportunities for external contributorshttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Up-for-Grabs%22
on Nov 15, 2021https://github.com/PowerShell/PowerShell/issues/9300#event-5620258356
https://github.com/apps/microsoft-github-policy-service
microsoft-github-policy-servicehttps://github.com/apps/microsoft-github-policy-service
on Nov 16, 2023https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-1813843353
Microsoft GitHub Policy Servicehttps://aka.ms/1es-gitops
https://github.com/apps/microsoft-github-policy-service
microsoft-github-policy-servicehttps://github.com/apps/microsoft-github-policy-service
on Nov 16, 2023https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-1813843354
Microsoft GitHub Policy Servicehttps://aka.ms/1es-gitops
https://github.com/apps/microsoft-github-policy-service
microsoft-github-policy-servicehttps://github.com/apps/microsoft-github-policy-service
on Nov 16, 2023https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-1813843355
Microsoft GitHub Policy Servicehttps://aka.ms/1es-gitops
microsoft-github-policy-servicehttps://github.com/apps/microsoft-github-policy-service
Resolution-No ActivityIssue has had no activity for 6 months or morehttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Resolution-No%20Activity%22
on Nov 16, 2023https://github.com/PowerShell/PowerShell/issues/9300#event-10976126098
https://github.com/apps/microsoft-github-policy-service
microsoft-github-policy-servicehttps://github.com/apps/microsoft-github-policy-service
on Nov 23, 2023https://github.com/PowerShell/PowerShell/issues/9300#issuecomment-1824373465
Microsoft GitHub Policy Servicehttps://aka.ms/1es-gitops
microsoft-github-policy-servicehttps://github.com/apps/microsoft-github-policy-service
completedhttps://github.com/PowerShell/PowerShell/issues?q=is%3Aissue%20state%3Aclosed%20archived%3Afalse%20reason%3Acompleted
on Nov 23, 2023https://github.com/PowerShell/PowerShell/issues/9300#event-11047305350
Ryan Yates (kilasuit)https://github.com/kilasuit
WG-Cmdletsgeneral cmdlet issueshttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22WG-Cmdlets%22
WG-Cmdlets-Utilityhttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22WG-Cmdlets-Utility%22
on Jul 17, 2026https://github.com/PowerShell/PowerShell/issues/9300#event-28140228010
Sign up for freehttps://github.com/signup?return_to=https://github.com/PowerShell/PowerShell/issues/9300
Sign in to commenthttps://github.com/login?return_to=https://github.com/PowerShell/PowerShell/issues/9300
Issue-BugIssue has been identified as a bug in the producthttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Issue-Bug%22
Resolution-No ActivityIssue has had no activity for 6 months or morehttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Resolution-No%20Activity%22
WG-Cmdletsgeneral cmdlet issueshttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22WG-Cmdlets%22
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.