Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

Support Set-PSBreakpoint showing breakpoints in the editor

Abierto
#1,091 1 comentario 1 reacción 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
38/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Estancado
Stack tecnológico
csharp, powershell
Área
devtools

Línea de trabajo

Comienza leyendo EditorObject.cs y el enfoque de proxy de Set-PSBreakpoint descrito en la issue. Sigue cómo se accede a JsonRpcServer o ILanguageServer y, después, revisa BreakpointEvent en la especificación de DAP y el tipo de protocolo referenciado. Se considera terminado cuando añadir un breakpoint mediante Set-PSBreakpoint notifica al editor con la información del breakpoint y cuenta con manejo de errores.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

Area-Debugging Issue-Enhancement

By creating a Proxy function of Set-PSBreakpoint, we can fire the breakpoint event as seen in the DAP spec to notify the client that a breakpoint has been added.

This is the really the final feature needed to provide the "console debugging in PSES experience" that feels totally integrated.

Creating a Proxy cmdlet is easy with:

$Metadata = [System.Management.Automation.CommandMetaData]::new((Get-Command Set-PSBreakpoint))
[System.Management.Automation.ProxyCommand]::Create($Metadata)

Then we'll need a way to give the EditorObject the state of the debugger... but mainly the JsonRpcServer object so that we can use it to send the SendNotification( method to send the breakpoint information to the client.

Then we take that proxy function and add something like:

$psEditor.Components
    .GetService([OmniSharp.Extensions.LanguageServer.Protocol.Server.ILanguageServer])
    .SendNotification("breakpoint", [OmniSharp.Extensions.DebugAdapter.Protocol.Events.BreakpointEvent]::new(<#...#>))

with some error handling and we should be good to go.

Lenguaje dominante
C#
Estrellas
767
Forks
266
Merge medio
3 d 16 h
PR fusionados (30 d)
1

Guía de contribución

Abrir la guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de PowerShell/PowerShellEditorServices

Todos los issues de PowerShell/PowerShellEditorServices

Issues similares

Más issues de C#

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.