AL icon indicating copy to clipboard operation
AL copied to clipboard

AL Language extension enters a perpetual loading/spinning state when opening a multi-root

Open louagej opened this issue 4 months ago • 5 comments

1. Describe the bug The AL Language extension enters a perpetual loading/spinning state when opening a multi-root .code-workspace that spans two repositories: a documentation-only repository (opened as ".") and an AL source repository (opened as a sibling path). The extension never completes initialization ΓÇö IntelliSense, diagnostics, and CodeLens are unavailable.

Image

2. To Reproduce

Steps to reproduce the behavior:

  1. Check out both repositories side-by-side:

    <customer>-docs/          ← documentation repo (MkDocs, no app.json)
    <customer>/               ← AL source repo
    
  2. Open the workspace file located in the documentation repo:

    {
      "folders": [
        { "path": "." },
        { "path": "../<customer>" }
      ],
      "settings": {
        "al.enableCodeAnalysis": true,
        "al.codeAnalyzers": ["${CodeCop}", "${UICop}", "${PerTenantExtensionCop}"],
        "al.ruleSetPath": "ruleset.json"
      }
    }
    
    • "." ΓåÆ Documentation repository ΓÇö no app.json at root (MkDocs site, markdown only)
    • "../<customer>" ΓåÆ AL source repository ΓÇö contains 3 AL projects nested under subfolders:
    Subfolder App ID platform / application AL files
    W1/<customer>.w1 2bb1a09a-… 26.0.0.0 / 26.0.0.0 ~31
    BE/<customer>.be 3fe87366-… 26.0.0.0 / 26.0.0.0 ~5
    W1/<customer>.w1.Test 8b7b806d-… depends on W1 + MS test libs ~1
  3. Observe the AL Language extension status bar item.

  4. Wait ΓÇö the spinner never stops and the extension never becomes ready.

3. Expected behavior The AL Language extension completes loading for all 3 AL projects found in the "../<customer>" folder and provides IntelliSense, diagnostics, and CodeLens normally.

4. Actual behavior The AL Language extension status bar item shows a perpetual loading/spinning indicator. [Attach screenshot or AL output channel log here.]

5. Versions:

  • AL Language: 17.0.2273547
  • Visual Studio Code: 1.127.0 (x64)
  • Business Central Version: 28.1
  • List of Visual Studio Code extensions installed:
  • Operating System:
    • [x] Windows
    • [ ] Linux
    • [ ] MacOS

Final Checklist

  • [x] Search the issue repository to ensure you are reporting a new issue
  • [x] Reproduce the issue after disabling all extensions except the AL Language extension
  • [x] Simplify your code around the issue to better isolate the problem Internal work item: AB#642076

louagej avatar Jul 07 '26 10:07 louagej

It happens also with a single folder project.

@esbenk any news?

By looking at the developer console, I saw this:

console.ts:139 [Extension Host] rejected promise not handled within 1 second: No AL workspace folder is active. An AL workspace is active, if a contained AL project is active. For example, if the keyboard focus is at a contained AL file or the app.json file.
log @ console.ts:139
$logExtensionHostMessage @ mainThreadConsole.ts:45
_doInvokeHandler @ rpcProtocol.ts:458
_invokeHandler @ rpcProtocol.ts:443
_receiveRequest @ rpcProtocol.ts:370
_receiveOneMessage @ rpcProtocol.ts:297
(anonymous) @ rpcProtocol.ts:159
_deliver @ event.ts:1391
fire @ event.ts:1422
fire @ ipc.net.ts:658
(anonymous) @ localProcessExtensionHost.ts:438

Extensions:

Name: AL Language extension for Microsoft Dynamics 365 Business Central
Id: ms-dynamics-smb.al
Description: Development tools for Dynamics 365 Business Central
Version: 18.0.2668733
Publisher: Microsoft
VS Marketplace Link: https://marketplace.visualstudio.com/items?itemName=ms-dynamics-smb.al

f4n0 avatar Aug 27 '26 10:08 f4n0

Any news? It is still broken

f4n0 avatar Aug 31 '26 09:08 f4n0

have the same issue, changing to pre-release worked, but then publishing becomes the problem.

Ugniusig avatar Sep 02 '26 07:09 Ugniusig

It is still broken even in pre-release. Waiting for fix.

arsag avatar Sep 02 '26 07:09 arsag

Same here, problem now occurs in new stable version 18.0.2726309. Revert to old stable 17.0.2273547 solves the problem.

lw-dwi avatar Sep 09 '26 14:09 lw-dwi