-
Notifications
You must be signed in to change notification settings - Fork 990
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[feature] Have trim_conandata
not throw when there's no conandata.yml
#15672
Comments
* Add trim_conandata() as hook - For #15672 * Fix test
Ideally, I'd like the /cc @memsharded wdyt? |
My suggestion is
If called from a recipe, these have control over: the argument passed, and whether conandata.yml exists. |
Not sure what you mean. I think recipes should call this explicitly, to be self-contained and not depend on a hook to do the right thing. Being a multi-version recipe is something that is specific to the recipe, so I'd like it to be part of the recipe by default. The hook approach is necessary because it will take a lot of time to get there. |
What is your suggestion?
trim_conandata
can be used inside apost_export
hook instead of theexport()
method in recipes, but then we have no control over wether a recipe has an associatedconandata.yml
.The fix is easy, just
try: ... catch:
it, but feels a bit dirty.Ideally that could be skipped, but it's true that when used in the
export
method, it might be desirable to have it raise, so we need to give it a thoughtReproducing this is easy: Have a simple recipe without a
conandata.yml
and apost_export
hook that simply callstrim_conandata
. That is, this test should pass, which currently does not:Have you read the CONTRIBUTING guide?
The text was updated successfully, but these errors were encountered: