Closed RobertRostohar closed 1 week ago
I cannot access https://github.com/RobertRostohar/Debug_VSC/tree/main/STM32F769I-EVAL/Network, is this a private repository?
When running a generator on a context, only that context should be checked.
Actually all contexts sharing the same path
and generator id
are siblings and will be checked.
https://github.com/Open-CMSIS-Pack/cmsis-toolbox/blob/main/docs/YML-Input-Format.md#generators---options
Once I have access to the repository I can investigate further.
The repo is now public, so you should be able to try it out.
The failure concerning the missing component and consequently the dependency check comes from a defect when processing sibling contexts that are not selected: packs that are additionally required by such contexts are not loaded.
As a workaround the call csolution run -g <generator> -c <context>...
should select all sibling contexts.
In this example all contexts are siblings because all share the same generator id
, base-dir
and cgen-file
(as can be seen by csolution list generators Network.csolution.yml -v
) so omitting the -c
is the workaround here:
csolution run Network.csolution.yml -g CubeMX
The command for the generator is from the VSC extension which means that you cannot use the extension out of the box.
I still believe that if you run a generator for a context from one project, other projects should not be checked.
I still believe that if you run a generator for a context from one project, other projects should not be checked.
I tend to disagree here. If a single generator (one *.ioc
project and one *.cgen.yml
) is used by multiple cproject.yml
the csolution run -G ...
will produce one cbuild-gen-idx.yml and all associated cbuild-gen.yml files.
csolution list generators project.csolution.yml -v
displays the contexts that share the identical generator and will select the set of contexts based on that.
csolution list generators USB_Device.csolution.yml -v
CubeMX (Global Registered Generator)
base-dir: Board/STM32F769I-EVAL/CubeMX
cgen-file: Board/STM32F769I-EVAL/CubeMX/Board.cgen.yml
context: HID.Debug+STM32F769NIHx
context: HID.Release+STM32F769NIHx
context: MassStorage.Debug+STM32F769NIHx
context: MassStorage.Release+STM32F769NIHx
context: VirtualCOM.Debug+STM32F769NIHx
context: VirtualCOM.Release+STM32F769NIHx
Actually all contexts sharing the same path and generator id are siblings and will be checked.
I would add another condition for the siblings (in addition to the above):
map:
(software mapping)You are right I forgot to mention those conditions but as far as I know these are considered already as well.
@RobertRostohar would you agree that this issue can be closed?
While I disagree with validation scope, the defect in the dependency check has been fixed and we can close this issue.
Note that I raise this issue https://github.com/ARM-software/vscode-cmsis-csolution/issues/121
Hence I'm closing it here.
Describe the bug It seems that when running the generator on a specific context the whole solution is being validated. This should not be the case. Only the selected context should be validated. But even worse, the dependency check fails when multiple contexts are available despite that every context on its own has no dependency issues.
To Reproduce A solution with multiple projects where projects have different components from different packs (packs are specified in the project). Running the generator on a context fails due to false dependency validation failure on a different context.
Example: https://github.com/RobertRostohar/Debug_VSC/tree/main/STM32F769I-EVAL/Network
Running the generator on a context from BSD_Client project:
csolution run Network.csolution.yml -g CubeMX -c BSD_Client.Debug+STM32F769I-EVAL
fails with the following error for the HTTPS_Server project:
However the HTTPS_Server project has no dependency issues.
When only a single project is part of the solution, running the generator on BSD_Client or HTTPS_Server project is successful.
Expected behavior When running a generator on a context, only that context should be checked. Also the dependency check should work correctly on a context and not be influenced by other contexts in the solution.
Environment: