microsoft / microsoft/AL

The launch startupcompany does not work when debugging

Open
#7,266 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

developer-productivity
Dominant language
PowerShell
Stars
881
Forks
285
Avg merge
3d 36m
Merged PRs (30d)
1

Description

1. Describe the bug
I would like to debug in a specific company using the new startupcompany setting. It does not work...

References:

image

2. To Reproduce
Steps to reproduce the behavior:

VS Code part

BC Part

  • My current user is linked to company 1 (my settings)

VS Code

  • Whenever I publish with/without debugging and select a configuration with a startupcompany different then company 1 (the default of the user in BC), it seems to be totally ignored.
  • The web client opens after the publish/debug step and uses the company as specified in the BC user settings, instead of the startupcompany specified in the launch configurations.

3. Expected behavior

  • startupcompany should be supported in all 'publish with/without debugging' commands.

4. Actual behavior

https://user-images.githubusercontent.com/25268332/205255214-82e4746b-a380-4aef-9a27-a8ab9d789eae.mp4

5. Versions:

  • AL Language: v10.1.707468
  • Visual Studio Code: 1.73.1
  • Business Central: US Business Central 21.1 (Platform 21.0.48357.49378 + Application 21.1.48363.48789)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue with an empty .vscode/launch.json and configurations in VS Code settings.json, selecting a startupcompany different from the Business Central user's default. Start by tracing the publish with and without debugging commands; done means each command opens the web client using the startupcompany from the selected launch configuration.

Written by the indexing model from the issue text.

Assessment

Tech stack
vscode
Domain
devtools
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.