Skip to content
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

Multiple flags lead to unexpected behavior #187

Closed
mblayman opened this issue Feb 21, 2024 · 2 comments
Closed

Multiple flags lead to unexpected behavior #187

mblayman opened this issue Feb 21, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@mblayman
Copy link

mblayman commented Feb 21, 2024

My team (from Included Health, a Codecov customer) has a couple of monorepos that need to upload coverage data.

The orb docs seem to indicate that we could associate multiple flags with a coverage file by using a comma separated list with no spaces (e.g., ui,chrome in the docs). The result of doing that lead to a joined flag that looked like:

image

Our config YAML looked like:

...
          flags: bundleapp,entityresolution,fhir_server,financialaccount_server,kafkatools_server
...

The orb says that flags is a string type so I attempted to switch to a string with some spacing like:

...
          flags: "bundleapp, entityresolution, fhir_server, financialaccount_server, kafkatools_server"
...

This version resulted in a parse error. /bin/bash: line 17: entityresolution: command not found

I took a closer look at the orb script and I'm not certain that the result would have worked anyway. The Codecov CLI uses the multiple argument for the -F flag definition on the CLI. The click docs show that the multiple option would expect to be used like -F flag_a -F flag_b. The orb script only uses a single -F that is prepended at the end of processing (i.e. -F flag_a,flag_b). I'm not sure that this would lead to a correct invocation of the upload CLI command (but I confuse I've not tested this. Perhaps click does some magic here).

For now, I've worked around this by calling the upload orb command once per flag, but this is less than ideal.

Thanks for providing the CircleCI orb. I hope this information helps to make improvements.

@thomasrockhu-codecov thomasrockhu-codecov added the bug Something isn't working label May 7, 2024
@thomasrockhu-codecov
Copy link
Contributor

@mblayman sorry for the delay here. we've released 5.0.0, can you see if this fixes your issue?

@mblayman
Copy link
Author

I think we have worked around this in some other way, so I'm no longer in a position to validate this change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants