
Fab Inspector for VS Code (Preview)
A Visual Studio Code extension that provides a seamless integration with the Fab Inspector CLI executable, enabling developers to analyze and inspect Microsoft Fabric CI/CD items with Fab Inspector rules directly from their VS Code workspace.
✏️ NOTE This is a community project that is not supported by Microsoft.
The repository for this extension can be found at https://github.com/NatVanG/fab-inspector-vscode-ext.
The repository for Fab Inspector (also known as PBI Inspector V2 - full name change pending) can be found at https://github.com/NatVanG/PBI-InspectorV2.
⚠️ Platform Support: This extension currently supports Windows only and requires the .NET 10.0 x64 runtime.
🚀 Features
📋 Commands
- Fab Inspector: Run - Rules file execution with customizable output formats (Console or HTML)
- Fab Inspector: Run Current Rules - Quick execution of the currently open rules file
- Fab Inspector: Run Selected Rule - Execute individual rules for quick testing and validation
- Fab Inspector: Create New Rules File - Creates a new rules file with a templated rule to get you started
🔧 JSON Rule Debug Commands
- Fab Inspector: Log Un\Wrap - Un\Wrap a selected Fab Inspector rule operation with log nodes for debug output to console
🔧 CLI Management Commands
- Fab Inspector: Update CLI - Manually download and update the Fab Inspector CLI
- Fab Inspector: Show CLI Info - Display current CLI version and status information
📁 Workspace Integration
- Rules Folder Support: Organize rules in the
fab-inspector-rules folder at the root of your VS Code folder
⬇️ Extension Installation
The entension can be installed from the Visual Studio Marketplace at https://marketplace.visualstudio.com/items?itemName=NatVanG.fab-inspector.
📋 Requirements
- Operating System: Windows (64-bit)
- .NET Runtime: .NET 10.0 (x64) must be installed
- Visual Studio Code: Version 1.102.0 or higher
- Internet Connection: Required for Fab Inspector CLI downloads.
Installing .NET 10
The extension requires the .NET 10.0 x64 runtime to execute the Fab Inspector CLI. .NET 8 and 9 do not satisfy this requirement; installing only a newer major runtime also does not replace .NET 10.
- Dependency check: The extension checks for a local .NET 10.0 runtime and provides a download link if it cannot find one. Closing the prompt or opening the download/settings page stops the inspection; retry after installing the runtime. Only disable this check if the required runtime is installed but cannot be detected.
- Download .NET 10 runtime: Visit https://dotnet.microsoft.com/en-us/download/dotnet/10.0 and select the Windows x64 .NET Runtime.
- Install: Run the installer and follow the setup instructions
Fab Inspector CLI
- Automatic Download: The Fab Inspector CLI is automatically downloaded when first needed from the "CLI" releases published to https://github.com/NatVanG/PBI-InspectorV2/releases.
- Version Management: Settings allow for configurable CLI version selection (latest or specific versions)
- Update Management: Settings allow for optional auto-updates of the CLI (enabled by default) with configurable cache expiry intervals
- Safe Updates: Downloads are extracted and validated in a separate staging directory before replacing the installed CLI. Failed downloads leave the existing installation untouched; a failed replacement attempts to restore it. Stop the Fab Inspector MCP server and any running inspections before updating.
💡 Note: Enabling auto-update is recommended to get the latest Fab Inspector CLI fixes and performance improvements.
Workspace Setup
- fab-inspector-rules folder: Create this folder in your workspace root for rules files. The folder name can be configured in the extension's settings, by default it's set to
fab-inspector-rules.
- JSON Files: Rules must be valid Fab Inspector Rules JSON files (with
.json extension) stored at the root of the fab-inspector-rules folder.
Your JSON rules files should follow the structure defined by the Fab Inspector (PBI Inspector V2) project, see resources below.
📚 Rule Creation Resources:
Example workspace folder:
Here is an example VS Code workspace folder. Note that, by default, a fab-inspector-rules folder must be present at the root of the workspace. In turm, the Fab Inspector rules file(s) must present at the root of the fab-inspector-rules folder. The default fab-inspector-rules folder can be renamed via the extension's settings.
📁 workspace/
├── 📁 fab-inspector-rules/
│ ├── report-rules.json
│ ├── advanced-rules.json
│ └── custom-validations.json
├── 📁 fabric-items/
│ ├── 📁 MyReport.Report/
│ │ ├── ...
│ │ └── .platform
│ ├── 📁 SalesDataset.SemanticModel/
│ │ ├── ...
│ │ └── .platform
│ └── 📁 ETLPipeline.DataPipeline/
│ │ ├── ...
│ │ └── .platform
Sample repository:
Here is an example repository with sample Microsoft Fabric CI/CD items and rules to get you started with the Fab Inspector VS Code extension: https://github.com/NatVanG/fab-inspector-cicd-example.
📖 Extension Usage Guide
1. Command Palette Operations
Fab Inspector: Run (Interactive)
The main inspection command that provides the ability to define output formats.
How to use:
- Open Command Palette (
Ctrl+Shift+P)
- Type and select
Fab Inspector: Run
- Follow the interactive prompts:
- Select Rules File: Choose from available
.json files in your fab-inspector-rules folder
- Select Output Format: Choose between
console or html. The console format logs test results to the "Fab Inspector" extension output channel in VS Code. The html option opens a browser page with locally generated HTML test results.
Fab Inspector: Update CLI
Manually download or update the Fab Inspector CLI to the latest version or the version specified in the extension's settings.
How to use:
- Open Command Palette (
Ctrl+Shift+P)
- Type and select
Fab Inspector: Update CLI
- The extension will download and install the latest Fab Inspector CLI version or the version specified in the extension's settings.
Fab Inspector: Show CLI Info
Display information about the current CLI installation and version.
How to use:
- Open Command Palette (
Ctrl+Shift+P)
- Type and select
Fab Inspector: Show CLI Info
- View CLI version, status, and configuration details
Fab Inspector: Run Current Rules
Quickly execute the currently open rules file without additional prompts.
How to use:
- Open a JSON rules file from your
fab-inspector-rules folder
- Right-click anywhere in the editor
- Select
Fab Inspector: Run Current Rules from the context menu
- The extension will automatically execute the current rules file with GitHub-compatible output format
Requirements:
- Rules file must be located at the root of the
fab-inspector-rules folder (itself at the root of the workspace)
- File must have a
.json extension
- File must contain valid Fab Inspector Rules JSON definition
Fab Inspector: Run Selected Rule (Single Rule Testing)
Execute individual rules for quick testing or rule debugging.
How to use:
- Select either a complete rule definition in your JSON editor or select the rule ID.
- Right-click the selection
- Choose
Fab Inspector: Run Selected Rule
- The extension will create a temporary rules file and execute just that rule
Fab Inspector: Log Wrap (JSON Wrapping)
Wrap selected JSON fragments with a log node for debugging or enhanced logging.
How to use:
- Select a valid Fab Inspector rule's operator JSON in your editor
- Right-click the selection
- Choose
Fab Inspector: Log Wrap
- The selected JSON will be wrapped with a
log node
Example:
// Before (selected):
{
"var": "visual.VisualType"
}
// After wrapping:
{
"log": {
"var": "visual.VisualType"
}
}
Fab Inspector: Log Unwrap (JSON Unwrapping)
Remove log wrapper from JSON operator.
How to use:
- Select a JSON object that contains a
log node
- Right-click the selection
- Choose
Fab Inspector: Log Unwrap
- The log wrapper will be removed, leaving only the inner JSON
Example:
// Before (selected):
{
"log": {
"var": "visual.VisualType"
}
}
// After unwrapping:
{
"var": "visual.VisualType"
}
🔧 Extension Settings
This extension exposes the following settings to VS Code:
| Setting |
Type |
Default |
Description |
fabInspector.autoUpdateCli |
boolean |
true |
Automatically check for and download CLI updates |
fabInspector.cliUpdateInterval |
number |
24 |
Hours between CLI update checks (when auto-update is enabled) |
fabInspector.cliVersion |
string |
"latest" |
Version of the Fab Inspector CLI to download. Use 'latest' for the most recent release, or specify a version tag like 'v4.0.1' |
Command Reference
| Command |
ID |
Trigger |
Context |
Description |
Fab Inspector: Run |
fab-inspector.inspect |
Command Palette |
Any time |
Interactive inspection with full options |
Fab Inspector: Run Current Rules |
fab-inspector.inspectWithCurrentRulesFile |
Right-click |
JSON files in rules folder |
Quick execution of current rules file |
Fab Inspector: Run Selected Rule |
fab-inspector.runRule |
Right-click |
JSON rule selection |
Execute single rule for testing |
Fab Inspector: Log Wrap |
fab-inspector.wrapWithLog |
Right-click |
JSON selection |
Wrap JSON fragment with log node |
Fab Inspector: Log Unwrap |
fab-inspector.unwrapLog |
Right-click |
JSON selection |
Remove log wrapper from JSON |
Fab Inspector: Update CLI |
fab-inspector.updateCli |
Command Palette |
Any time |
Manually update CLI to latest version |
Fab Inspector: Show CLI Info |
fab-inspector.cliInfo |
Command Palette |
Any time |
Display CLI version and status |
🐛 Troubleshooting
Common Issues
".NET 10.0 runtime not installed"
- Install the Windows x64 .NET 10 runtime, then restart VS Code and retry.
- Run
dotnet --list-runtimes --arch x64 and check for Microsoft.NETCore.App 10.0.x. Having only .NET 8, 9, another major version, or an x86 runtime is not sufficient.
"No rules files found"
- ✅ Ensure
fab-inspector-rules folder exists in workspace root
- ✅ Verify files have
.json extension
- ✅ Check that JSON syntax is valid
"Right-click commands not appearing"
- ✅ Ensure you're working with a
.json file
- ✅ For selection-based commands, make sure a valid JSON fragment or rule ID is selected
- ✅ For rules file execution, ensure file is in the
fab-inspector-rules folder
"Rule execution failed"
- ✅ Verify rule has valid JSON Logic syntax
- ✅ Ensure CLI is properly downloaded and accessible
"CLI download failed"
- ✅ Check internet connection
- ✅ Verify Windows firewall/antivirus isn't blocking downloads
- ✅ Try manually updating CLI using
Fab Inspector: Update CLI command
- ✅ Check VS Code output panel for detailed error messages
"EBUSY: resource busy or locked" when updating the CLI
Windows cannot replace the CLI executable while it is running, including when it is being used as the Fab Inspector MCP server.
- Open the Command Palette and run
MCP: List Servers.
- Select
Fab Inspector MCP, then select Stop. Stop the server in other VS Code windows or Copilot sessions using the same installation too.
- Run
Fab Inspector: Update CLI again.
- Start the Fab Inspector MCP server again after the update succeeds.
If the server automatically restarts before the update completes, temporarily disable its automatic startup. Also wait for any running Fab Inspector inspections to finish before retrying. Repeated download attempts cannot release a lock held by a running process.
"Temporary file errors"
- ✅ Check workspace permissions for
.vscode folder creation
- ✅ Restart VS Code to clear any locked temporary files
- ✅ Verify sufficient disk space in workspace directory
- Large Rule Sets: Split complex rule sets into multiple files for easier management
- Quick Testing: Use
Fab Inspector: Run Selected Rule for rapid iteration during development
- Output Format: Use
console format for fastest execution, html for visual output
- CLI Updates: Keep CLI up-to-date or specify 'latest' version in the extension settings for best performance and latest features
🔄 Known Issues and Limitations
Current Limitations
- Platform Support: Windows 64-bit only.
- CLI Dependency: Requires internet connection for initial CLI download and the .NET 10.0 x64 runtime.
- JSON Rules Only: Rules files must be valid JSON (JSONC/comments not supported)
Building and Releasing
Use Node.js 24 LTS and npm ci. Run npm test and npm run package to validate and package the extension. Packaging builds the production bundle automatically. CI uses the lockfile-installed vsce, not a globally installed latest version.
- Update the version with
npm version <version> --no-git-tag-version and commit both package.json and package-lock.json, along with the release changes.
- Run Release Extension on that commit. It tests on Windows against the minimum supported VS Code version and current stable, packages the extension, tags the source commit, and creates a GitHub pre-release with the VSIX.
- The release workflow explicitly calls Publish to VS Code Marketplace, which downloads and publishes that exact release VSIX without rebuilding it. Publishing uses GitHub OIDC (
vsce publish --oidc), not a Marketplace PAT.
Before publishing, open publisher NatVanG at Visual Studio Marketplace publisher management and select Trusted Publishing. Configure policies for both workflow entry points:
| Field |
Release policy |
Direct publish/retry policy |
| Policy name |
Fab Inspector release |
Fab Inspector publish |
| Repository owner |
NatVanG |
NatVanG |
| Repository |
fab-inspector-vscode-ext |
fab-inspector-vscode-ext |
| Workflow |
release.yml |
publish.yml |
| Environment (optional) |
Leave empty |
Leave empty |
The release entry point calls the reusable publishing workflow; the direct entry point supports manual retries and release events. Neither job uses a GitHub environment. Both the caller and publishing job grant id-token: write. See the Trusted Publishing setup guide.
Commit and push these changes before running the workflows. After the first successful OIDC publication, delete the unused VSCE_PAT repository secret and revoke its PAT. For a private repository, run each configured entry point within 48 hours of creating its policy to activate it.
To retry a failed Marketplace publication, manually run Publish to VS Code Marketplace from the updated branch with the existing release tag (for example v0.0.18). This workflow never bumps versions or creates a new package. It installs lockfile-pinned publishing tools from the workflow commit, so older release tags do not select an older, PAT-only CLI. It verifies the downloaded VSIX's name, publisher, and version against the selected tag. Manually published GitHub releases also trigger it; attach the matching VSIX before publishing the release.
The GitHub release remains marked as a pre-release; Marketplace publication retains the existing normal-channel behavior.
Feedback
If you encounter issues or have suggestions for improvements, please:
🎉 Enjoy inspecting and validating your Microsoft Fabric items with enhanced productivity!