espressif / idf-component-manager

Tool for installing ESP-IDF components
https://components.espressif.com/
Apache License 2.0
46 stars 16 forks source link

Unable to incorporate a component with an override_path via Git (PACMAN-775) #45

Open leeebo opened 11 months ago

leeebo commented 11 months ago

The Component Manager version

v1.4.1

ESP-IDF Version

master (5.3)

python Version

3.10

Operating System

Ubuntu

Browser (for https://components.espressif.com Issues)

No response

Description

CMake Error at /home/xuxin/esp/esp-idf-github-clean/tools/cmake/build.cmake:544 (message):
ERROR: The 'override_path' field in the manifest file
../rmaker common/idf component.yml' does not point to a directory. You
can safely remove this field from the manifest if this proiect is an
example copied from a component repository.
The dependency will be
downloaded from the Esp component registry. Documentation:
https://docs.espressif.com/projects/idf-component-manager/en/latest/reference/manifest file.html #foverride-path

To Reproduce

espressif/esp_schedule:
  path:components/esp_schedule
  git:https://github.com/espressif/esp-rainmaker.git
  version:"7d4c1e36f9110e04c30c21a708762ed91eea99ac"

Expected behaviour

Component manager Handle/Delete the override_path in the yml

Additional info

No response

I have checked existing issues and online Documentation

kumekay commented 11 months ago

Hi @leeebo

Thank you for opening the topic, Your use case is not the one we considered for the feature. I.e., the expected flow is to make a clone of the entire Rainmaker repository manually and then use a directory as a local dependency or using EXTRA_COMPONENT_DIRS

We can, however, support this case, by ignoring override_path for git components, but in this case, it will download rainmaker_common from the registry. We can also print a warning when it happens. What do you think?

But unfortunately, we cannot make override_path just work because here component manager operates with git dependencies at the level of individual components, not a whole repo.

leeebo commented 11 months ago

Hi @kumekay, we need the workaround because there is a use case: the fix already be merged, but not be released to esp-registry.

How about just ignore the override_path? then print message tell which version it actually using. Prompt warning is not recommended, because CI Build processes Do Not allow warnings in the CMake process also.

kumekay commented 11 months ago

@leeebo Ok, I'll check how we can quickly implement it

igrr commented 11 months ago

the fix already be merged, but not be released to esp-registry

Probably worth asking, what is the problem making a release? Is it not easier to fix that problem than to add a new feature to work around the problem?

leeebo commented 11 months ago

what is the problem making a release?

This is up to the maintainer of the component, and we have no control over it.

leeebo commented 11 months ago

@igrr While this leads to another topic, What is the recommended component release workflow to follow? 🤔

If a repository only has one component, we can maintain different major or minor versions with different branches, but if a component is only part of a larger repository, maintaining versions becomes more complicated.