René's URL Explorer Experiment


Title: Write event on configurationDone for attach requests · Issue #2245 · PowerShell/PowerShellEditorServices · GitHub

Open Graph Title: Write event on configurationDone for attach requests · Issue #2245 · PowerShell/PowerShellEditorServices

X Title: Write event on configurationDone for attach requests · Issue #2245 · PowerShell/PowerShellEditorServices

Description: Prerequisites I have written a descriptive issue title. I have searched all issues to ensure it has not already been requested. Summary On attach scenarios, it is not possible to wait for all the breakpoints set by the client to be set i...

Open Graph Description: Prerequisites I have written a descriptive issue title. I have searched all issues to ensure it has not already been requested. Summary On attach scenarios, it is not possible to wait for all the b...

X Description: Prerequisites I have written a descriptive issue title. I have searched all issues to ensure it has not already been requested. Summary On attach scenarios, it is not possible to wait for all the b...

Opengraph URL: https://github.com/PowerShell/PowerShellEditorServices/issues/2245

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Write event on configurationDone for attach requests","articleBody":"### Prerequisites\n\n- [x] I have written a descriptive issue title.\n- [x] I have searched all [issues](https://github.com/PowerShell/PowerShellEditorServices/issues?q=is%3Aissue) to ensure it has not already been requested.\n\n### Summary\n\nOn attach scenarios, it is not possible to wait for all the breakpoints set by the client to be set in the remote runspace. A client could have something like\n\n```powershell\n$originalRunspaces = Get-Runspace\n\nRead-Host -Prompt \"Please attach to process $pid with runspace $([Runspce]::DefaultRunspace.Id)\"\n\n# Waits for VSCode to attach to runspace, an extra runspace will be created by\n# Enter-PSHostProcess\nwhile ($true) {\n    $newRunspace = Get-Runspace | Where-Object { $_.Id -notin $runspaces.Id } | Select-Object -First 1\n    if ($newRunspace) {\n        break\n    }\n    Start-Sleep -Milliseconds 300\n}\n\n\u0026 .\\script.ps1\n```\n\nBut this only checks that PSES has attached to the named pipe. It won't wait for PSES to have called `Debug-Runspace` on the target runspace and more importantly any breakpoints inside `script.ps1` to be set. It's also error prone if you cannot control when the attach actually happens as the additional runspace check could have occurred before the first `Get-Runspace` call.\n\nWhat would be ideal is for a well known event to be created by PSES when `configurationDone` was received so that the client only had to do\n\n```powershell\n# Attach to this runspace somehow\n\n$e = Wait-Event -SourceIdentifier PSES.ConfigurationDone -Timeout 30\nif ($e) {\n    $e | Remove-Event\n}\nelse {\n    throw \"Timed out waiting for attach event\"\n}\n```\n\n### Proposed Design\n\nMy proposal requires some changes to PowerShell itself but I wanted to see if the general idea was acceptable before trying to propose the change there. The benefit of using an event is that no custom functions needed to be loaded, and subsequently checked by the code, and `Wait-Event` has a simple timeout operation.\n\nUltimately what needs to happen is for PowerShell to expose a `__New-Event` command, similar to the new `__Set-PSBreakpoint` commands, that is treated specially by the PSRemoting server. This would be able to do the following but without having to spin up a new pipeline.\n\n```\n$runspace = Get-Runspace -Id $runspaceId\n$runspace.Events.GenerateEvent($SourceId, $Sender, $EventArgs, $EventData)\n```\n\nWe cannot just have PSES run this script or call `New-Event` directly as the runspace pipeline is busy running `Debug-Runspace`. The only time it can run commands is if the caller ran `Wait-Debugger` which is not ideal as it will pause the execution and require the client to continue on manually.\n\nAn alternative that I haven't tried out yet is to delay `Debug-Runspace` until after `configurationDone` is sent. This would allow both the breakpoints and event to be manually emited as commands on the runspace specified without having to block the pipeline with `Debug-Runspace`. I am not sure if that will be possible though but it could be an option that doesn't require any changes to PowerShell itself.","author":{"url":"https://github.com/jborean93","@type":"Person","name":"jborean93"},"datePublished":"2025-07-23T04:29:54.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":3},"url":"https://github.com/2245/PowerShellEditorServices/issues/2245"}

route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:88c818e4-ed1e-7994-7eb9-9571cb043aa5
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idEC34:52C87:617002:8753D0:6A5854CC
html-safe-nonce48993fdd4600487a8545150a9c3f6063f953f10365bb394cedb45629d76753f9
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFQzM0OjUyQzg3OjYxNzAwMjo4NzUzRDA6NkE1ODU0Q0MiLCJ2aXNpdG9yX2lkIjoiNzg1NjM0MjI1MjUwMzE5Mjc4MCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmacb74fd162fc7477ffd9715766bf4fab39eb44713c4d33ef03ddca3263a09f9e8f
hovercard-subject-tagissue:3254816605
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/PowerShellEditorServices/2245/issue_layout
twitter:imagehttps://opengraph.githubassets.com/033cbbf109ff1fb9b8eadf6cfbfa9b52a439e49ac90a88ca0e442ccd842c6068/PowerShell/PowerShellEditorServices/issues/2245
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/033cbbf109ff1fb9b8eadf6cfbfa9b52a439e49ac90a88ca0e442ccd842c6068/PowerShell/PowerShellEditorServices/issues/2245
og:image:altPrerequisites I have written a descriptive issue title. I have searched all issues to ensure it has not already been requested. Summary On attach scenarios, it is not possible to wait for all the b...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamejborean93
hostnamegithub.com
expected-hostnamegithub.com
None5f2a0c7865178af3d91dd9f13b0cdfc3c73a2529c873d2780bb4c01271a57ec6
turbo-cache-controlno-preview
go-importgithub.com/PowerShell/PowerShellEditorServices git https://github.com/PowerShell/PowerShellEditorServices.git
octolytics-dimension-user_id11524380
octolytics-dimension-user_loginPowerShell
octolytics-dimension-repository_id36031537
octolytics-dimension-repository_nwoPowerShell/PowerShellEditorServices
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id36031537
octolytics-dimension-repository_network_root_nwoPowerShell/PowerShellEditorServices
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
release8aae7b8d6caacacf5c66eaeb2702d8dc88d85b4a
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/PowerShell/PowerShellEditorServices/issues/2245#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FPowerShell%2FPowerShellEditorServices%2Fissues%2F2245
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
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
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/open-source/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/open-source/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://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
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FPowerShell%2FPowerShellEditorServices%2Fissues%2F2245
Sign up https://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%2FPowerShellEditorServices
Reloadhttps://github.com/PowerShell/PowerShellEditorServices/issues/2245
Reloadhttps://github.com/PowerShell/PowerShellEditorServices/issues/2245
Reloadhttps://github.com/PowerShell/PowerShellEditorServices/issues/2245
Please reload this pagehttps://github.com/PowerShell/PowerShellEditorServices/issues/2245
PowerShell https://github.com/PowerShell
PowerShellEditorServiceshttps://github.com/PowerShell/PowerShellEditorServices
Notifications https://github.com/login?return_to=%2FPowerShell%2FPowerShellEditorServices
Fork 260 https://github.com/login?return_to=%2FPowerShell%2FPowerShellEditorServices
Star 759 https://github.com/login?return_to=%2FPowerShell%2FPowerShellEditorServices
Code https://github.com/PowerShell/PowerShellEditorServices
Issues 127 https://github.com/PowerShell/PowerShellEditorServices/issues
Pull requests 14 https://github.com/PowerShell/PowerShellEditorServices/pulls
Actions https://github.com/PowerShell/PowerShellEditorServices/actions
Security and quality 0 https://github.com/PowerShell/PowerShellEditorServices/security
Insights https://github.com/PowerShell/PowerShellEditorServices/pulse
Code https://github.com/PowerShell/PowerShellEditorServices
Issues https://github.com/PowerShell/PowerShellEditorServices/issues
Pull requests https://github.com/PowerShell/PowerShellEditorServices/pulls
Actions https://github.com/PowerShell/PowerShellEditorServices/actions
Security and quality https://github.com/PowerShell/PowerShellEditorServices/security
Insights https://github.com/PowerShell/PowerShellEditorServices/pulse
#2250https://github.com/PowerShell/PowerShellEditorServices/pull/2250
Write event on configurationDone for attach requestshttps://github.com/PowerShell/PowerShellEditorServices/issues/2245#top
#2250https://github.com/PowerShell/PowerShellEditorServices/pull/2250
Issue-EnhancementA feature request (enhancement).https://github.com/PowerShell/PowerShellEditorServices/issues?q=state%3Aopen%20label%3A%22Issue-Enhancement%22
Needs: TriageMaintainer attention needed!https://github.com/PowerShell/PowerShellEditorServices/issues?q=state%3Aopen%20label%3A%22Needs%3A%20Triage%22
https://github.com/jborean93
jborean93https://github.com/jborean93
on Jul 23, 2025https://github.com/PowerShell/PowerShellEditorServices/issues/2245#issue-3254816605
issueshttps://github.com/PowerShell/PowerShellEditorServices/issues?q=is%3Aissue
Issue-EnhancementA feature request (enhancement).https://github.com/PowerShell/PowerShellEditorServices/issues?q=state%3Aopen%20label%3A%22Issue-Enhancement%22
Needs: TriageMaintainer attention needed!https://github.com/PowerShell/PowerShellEditorServices/issues?q=state%3Aopen%20label%3A%22Needs%3A%20Triage%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.