VS Code\PowerShell - "Formatting Document" Long Execution Time

オープン
#984 コメント 30 件 リアクション 11 件 担当者 0 名 GitHub で見る

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

評価

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

調査の方向性

まず添付された settings.json とログアーカイブを確認し、次に VS Code で PowerShell スクリプトを使って保存時のフォーマットを再現します。拡張機能のフォーマット処理経路を追跡し、snippet や IntelliSense をブロックせずにフォーマットが速やかに完了することを確認します。報告された環境の詳細全体で動作を確認してください。

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

説明

Area-Code Formatting Issue-Performance
System Details
  • Operating system name and version: Windows 10 Ent x64
  • VS Code version: 1.14.2 (Latest)
  • PowerShell extension version: 1.4.1 (Latest)
  • Output from $PSVersionTable:

Name Value


PSVersion 5.1.15063.483
PSEdition Desktop
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 10.0.15063.483
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1

Copy / paste the following commands into the PowerShell Integrated Console, and paste the output here:

code -v
1.14.2
cb82febafda0c8c199b9201ad274e25d9a76874e

$pseditor.EditorServicesVersion
Major Minor Build Revision


1 4 1 0

code --list-extensions --show-versions
ms-vscode.PowerShell@1.4.1

$PSVersionTable
v-toddle.microsoft.com.zip
Name Value


PSVersion 5.1.15063.483
PSEdition Desktop
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 10.0.15063.483
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1

Issue Description

Hello! I posted this to VS Code and they referred me here (https://github.com/Microsoft/vscode/issues/31985#issuecomment-320095822)

I've noticed over the last couple days/week that VS Code is taking a very long time on "Formatting Document". I have my VS Code instance configured to format the document on every save, and I save constantly, so this is a real PITA. :( I have attached the contents of $env:APPDATA\Code\User to this report.

Steps to Reproduce

Steps to Reproduce:

Configure VS Code using my settings.json
Open up any Posh Script. I have encountered this on scripts with as few as 120 lines
Make a change
Save file
Blue bar at bottom of VS Code states "Formatting Document". VS Code is responsive, but Snippets and Intellisense do not function until it completes doing whatever it was doing.
Reproduces without extensions: No

Attached Logs

v-toddle.microsoft.com.zip

Follow the instructions in the README
about capturing and sending logs.

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

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

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

はじめの一歩

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

PowerShell/vscode-powershell のほかの issue

PowerShell/vscode-powershell の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

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

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