René's URL Explorer Experiment


Title: The ParseError "The Try statement is missing its Catch or Finally block" works only one way. · Issue #25491 · PowerShell/PowerShell · GitHub

Open Graph Title: The ParseError "The Try statement is missing its Catch or Finally block" works only one way. · Issue #25491 · PowerShell/PowerShell

X Title: The ParseError "The Try statement is missing its Catch or Finally block" works only one way. · Issue #25491 · PowerShell/PowerShell

Description: A ParseError is generated if "The Try statement is missing its Catch or Finally block" works only one way." but not vice versa: if "The Catch or Finally statement is missing its Try block". See also: PowerShell/PSScriptAnalyzer#2098 Expe...

Open Graph Description: A ParseError is generated if "The Try statement is missing its Catch or Finally block" works only one way." but not vice versa: if "The Catch or Finally statement is missing its Try block". See als...

X Description: A ParseError is generated if "The Try statement is missing its Catch or Finally block" works only one way." but not vice versa: if "The Catch or Finally statement is missing its...

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

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"The ParseError \"The Try statement is missing its Catch or Finally block\" works only one way.","articleBody":"A ParseError is generated if \"The Try statement is missing its Catch or Finally block\" works only one way.\" but not vice versa: if \"The Catch or Finally statement is missing its Try block\".\n\nSee also: https://github.com/PowerShell/PSScriptAnalyzer/issues/2098\n\n### Expected behavior\n\nA simular behavior for both situations, meaning:\nAn error when invokeing the following script:\n\n```PowerShell\nInvoke-ScriptAnalyzer -ScriptDefinition {function Test { Catch { write-verbose 'Test' } }}.ToString()\n```\n\nOr visa verse (no errors at alll), knowing that a  standalone `Try` (e.g.: `$a = try { 1 / $b }`) makes more sense than a standalone `Catch`.\n\n### Actual behavior\n\nDifferent behavior on the symmetrical situation.\n\n### Environment data\n\n```powershell\nVersion 7.5.1\n```\n","author":{"url":"https://github.com/iRon7","@type":"Person","name":"iRon7"},"datePublished":"2025-05-01T07:22:44Z","url":"https://github.com/PowerShell/PowerShell/issues/25491"}

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:22689c9b-8b13-239a-bca8-9210ebb4c8cb
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idE468:3550D1:444C2B:5A1235:6AFCEA8E
html-safe-nonce7f53dd016d19c18ba112176e74b6d457cca083c89068ecaa8c4ef74cee913a11
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFNDY4OjM1NTBEMTo0NDRDMkI6NUExMjM1OjZBRkNFQThFIiwidmlzaXRvcl9pZCI6IjM5OTU1OTUwMzM0NDgwODIwNjIiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmacf63756a7dcfbbf77d148c0aa00148e8a0a8c1b8c0e87e58eebfe0ceedd31a4e1
hovercard-subject-tagissue:3033320836
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/25491/issue_layout
twitter:imagehttps://opengraph.githubassets.com/6319086fb19141035519cacc7034e0881ae04ecbd15548364662cda3e00d6621/PowerShell/PowerShell/issues/25491
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/6319086fb19141035519cacc7034e0881ae04ecbd15548364662cda3e00d6621/PowerShell/PowerShell/issues/25491
og:image:altA ParseError is generated if "The Try statement is missing its Catch or Finally block" works only one way." but not vice versa: if "The Catch or Finally statement is missing its Try block". See als...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernameiRon7
hostnamegithub.com
expected-hostnamegithub.com
None99aede4c5f55ec5cf06666a8c9e03ebf9f85f7231223e7f1c38c16e5504835b3
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
releaseecfd63ca125ec74b42f74eeb158b3fa081c8c497
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/PowerShell/PowerShell/issues/25491#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FPowerShell%2FPowerShell%2Fissues%2F25491
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%2F25491
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/25491
Reloadhttps://github.com/PowerShell/PowerShell/issues/25491
Reloadhttps://github.com/PowerShell/PowerShell/issues/25491
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 requests364 (364)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/25491
New issuehttps://github.com/login?return_to=https://github.com/PowerShell/PowerShell/issues/25491
The ParseError "The Try statement is missing its Catch or Finally block" works only one way.https://github.com/PowerShell/PowerShell/issues/25491#top
Resolution-By DesignThe reported behavior is by design.https://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Resolution-By%20Design%22
WG-Enginecore PowerShell engine, interpreter, and runtimehttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22WG-Engine%22
WG-Languageparser, language semanticshttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22WG-Language%22
https://github.com/iRon7
iRon7https://github.com/iRon7
on May 1, 2025https://github.com/PowerShell/PowerShell/issues/25491#issue-3033320836
PowerShell/PSScriptAnalyzer#2098https://github.com/PowerShell/PSScriptAnalyzer/issues/2098
iRon7https://github.com/iRon7
Needs-TriageThe issue is new and needs to be triaged by a work group.https://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Needs-Triage%22
on May 1, 2025https://github.com/PowerShell/PowerShell/issues/25491#event-17484694298
https://github.com/MartinGC94
MartinGC94https://github.com/MartinGC94
on May 1, 2025https://github.com/PowerShell/PowerShell/issues/25491#issuecomment-2844388047
https://github.com/iRon7
iRon7https://github.com/iRon7
on May 1, 2025https://github.com/PowerShell/PowerShell/issues/25491#issuecomment-2844415966
MartinGC94https://github.com/MartinGC94
reserved wordshttps://learn.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_redirection
PowerShell/PSScriptAnalyzer#2099https://github.com/PowerShell/PSScriptAnalyzer/issues/2099
Ilya (iSazonov)https://github.com/iSazonov
WG-Enginecore PowerShell engine, interpreter, and runtimehttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22WG-Engine%22
WG-Languageparser, language semanticshttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22WG-Language%22
on May 1, 2025https://github.com/PowerShell/PowerShell/issues/25491#event-17486987156
https://github.com/iSazonov
Ilya (iSazonov)https://github.com/iSazonov
on May 1, 2025https://github.com/PowerShell/PowerShell/issues/25491#issuecomment-2844766771
https://github.com/rhubarb-geek-nz
rhubarb-geek-nzhttps://github.com/rhubarb-geek-nz
on May 1, 2025https://github.com/PowerShell/PowerShell/issues/25491#issuecomment-2845247120
foreachhttps://learn.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_reserved_words?view=powershell-7.5
ForEach-Objecthttps://learn.microsoft.com/en-us/powershell/module/microsoft.powershell.core/foreach-object?view=powershell-7.5
https://github.com/SeeminglyScience
Patrick Meinecke (SeeminglyScience)https://github.com/SeeminglyScience
on May 1, 2025https://github.com/PowerShell/PowerShell/issues/25491#issuecomment-2845323165
reserved wordshttps://learn.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_redirection
PowerShell/PSScriptAnalyzer#2099https://github.com/PowerShell/PSScriptAnalyzer/issues/2099
https://github.com/mklement0
Michael Klement (mklement0)https://github.com/mklement0
on May 1, 2025https://github.com/PowerShell/PowerShell/issues/25491#issuecomment-2845360831
https://github.com/SeeminglyScience
Patrick Meinecke (SeeminglyScience)https://github.com/SeeminglyScience
on May 5, 2025https://github.com/PowerShell/PowerShell/issues/25491#issuecomment-2851915260
Patrick Meinecke (SeeminglyScience)https://github.com/SeeminglyScience
Resolution-By DesignThe reported behavior is by design.https://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Resolution-By%20Design%22
Needs-TriageThe issue is new and needs to be triaged by a work group.https://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Needs-Triage%22
on May 5, 2025https://github.com/PowerShell/PowerShell/issues/25491#event-17524013947
https://github.com/iRon7
iRon7https://github.com/iRon7
on May 5, 2025https://github.com/PowerShell/PowerShell/issues/25491#issuecomment-2851935266
https://github.com/apps/microsoft-github-policy-service
microsoft-github-policy-servicehttps://github.com/apps/microsoft-github-policy-service
on May 7, 2025https://github.com/PowerShell/PowerShell/issues/25491#issuecomment-2857140121
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 May 7, 2025https://github.com/PowerShell/PowerShell/issues/25491#event-17549366362
https://github.com/apps/microsoft-github-policy-service
microsoft-github-policy-servicehttps://github.com/apps/microsoft-github-policy-service
on May 7, 2025https://github.com/PowerShell/PowerShell/issues/25491#issuecomment-2857140271
Microsoft GitHub Policy Servicehttps://aka.ms/1es-gitops
iRon7https://github.com/iRon7
https://aka.ms/PSRepoFeedbackhttps://aka.ms/PSRepoFeedback
Microsoft Formshttps://aka.ms/PSRepoFeedback
Sign up for freehttps://github.com/signup?return_to=https://github.com/PowerShell/PowerShell/issues/25491
Sign in to commenthttps://github.com/login?return_to=https://github.com/PowerShell/PowerShell/issues/25491
Resolution-By DesignThe reported behavior is by design.https://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Resolution-By%20Design%22
WG-Enginecore PowerShell engine, interpreter, and runtimehttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22WG-Engine%22
WG-Languageparser, language semanticshttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22WG-Language%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.