zjffun / vscode-snippets-manager

Create and edit snippets easily.
https://marketplace.visualstudio.com/items?itemName=zjffun.snippetsmanager
MIT License
36 stars 5 forks source link

Parse error output is not useful #13

Closed ryanspain closed 1 year ago

ryanspain commented 1 year ago

Addressed in PR #14.

I'll explain this ~bug~ issue with reference to the below screenshot.

image

  1. If a snippet file fails to parse (e.g. because of a trailing comma).
  2. The code snippet will not load in the Snippets Manager tab.
  3. The output log for Snippets Manager only logs "Parse error".

I traced this error message to CodeSnippetsService.ts.

Ideally, the log should include at a minimum the snippet file name and line number to guide someone down the right path.

zjffun commented 1 year ago

I agree. Thank you for your PR.

zjffun commented 1 year ago

I merged the PR above, and update the message to correspond with the Status Bar. This will publish in next version. Thanks again.

Screen Shot 2023-04-22 at 15 31 11
zjffun commented 1 year ago

Release v0.1.18 published. 🎉