PowerShell / PowerShell/vscode-powershell

Comment-Based Help after function name indents improperly on "Format Document"

オープン
#3,926 コメント 7 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

Area-Code Formatting Issue-Bug
主要言語
TypeScript
スター
1.9k
フォーク
548
PR マージ指標
30日以内にマージされた PR はありません

説明

Prerequisites
  • I have written a descriptive issue title.
  • I have searched all issues to ensure it has not already been reported.
  • I have read the troubleshooting guide.
  • I am sure this issue is with the extension itself and does not reproduce in a standalone PowerShell instance.
  • I have verified that I am using the latest version of Visual Studio Code and the PowerShell extension.
  • If this is a security issue, I have read the security issue reporting guidance.
Summary

Comment block indents during formatting when it shouldn't. Doesn't occur if block is above the function or if the whole block is already indented.

PowerShell Version
Latest
Visual Studio Code Version
1.67.0-insider
e6d98a13fcd3bf928d0e755eaae873ac200a98bd
x64
Extension Version
ms-vscode.powershell-preview@2022.4.1
Steps to Reproduce
  1. Create Function
  2. Comment based help on same line as function
  3. Format document or format-on-save
Visuals

https://user-images.githubusercontent.com/15258962/163913559-fd6f3949-1f40-433f-820b-6e81e995711c.mp4

Logs

No response

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

調査の方向性

関数と同じ行にあるコメントベースのヘルプ ブロックを使用して PowerShell 拡張機能で問題を再現し、その後 Format Document と format-on-save を適用します。誤ったインデントの原因となっているフォーマット動作を追跡し、issue に記載されたケースを退行させることなく、ブロックが正しく配置されたままであることを確認します。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
powershell, typescript, vscode
領域
tooling
issue の種類
バグ
難易度
3/5
見積もり時間
1〜2日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
35/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。