-
Notifications
You must be signed in to change notification settings - Fork 3
Description
Description
I am trying to develop a new build provider. For now I have a dummy one with a method isEligible() that always returns true and return a dummy target.
However, in a workspace with 5 opened projects, I get only one of the expected target.
For now, my workaround would be that my build provider class instances should manage a global map (one item per instance, identified by the working directory of the project) and the settings() method would return a concatenation of all the targets.
I believe that I have followed the directions described in the create-provider.md documents to get a valid minimal provider.
Also, while tinkering with my code, I could see that the settings() method of each instance of the provider is called.
And finally after a quick glance at target-manager.js->refreshTargets() I did not see where things could go wrong.
Steps to Reproduce
- clone this project https://github.com/sporniket/cmake-build-provider-for-pulsar
- invoke
npm installto install dependencies - invoke
npm run rebuild-cjsto build the plugin - invoke ppm to "install" this plugin
- invoke pulsar with a workspace with multiple projects
Expected behavior:
When displaying the target selection, one target per project should be listed, e.g here a capture of my workaround :
Actual behavior:
Only one target appear, the target from the build provider instance that has been called last.
Reproduces how often:
Always
Versions
Pulsar : 1.130.1-dev
Electron: 12.2.3
Chrome : 89.0.4389.128
Node : 14.16.0
ppm 2.7.0
npm 6.14.19-pulsar2
node 16.0.0 x64
pulsar 1.130.1-dev
python
git 2.43.0
OS : Ubuntu 24.04.3 LTS
Additional Information
My workaround can be seen by checking out the branch named fix--buidium-fails-to-aggregate-all-the-targets, rebuild the plugin and restart.
In this workaround, each instance manage its targets in a global object, and the settings() method concatenates all the targets.