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

Display warning if the compilation database is empty #4226

Merged
merged 1 commit into from
Apr 24, 2024

Conversation

noraz31
Copy link
Collaborator

@noraz31 noraz31 commented Apr 23, 2024

Change the log level from info to warning when
nothing was analyzed due to eg an empty
compilation database.
Fixes #4222

Change the log level from info to warning when
nothing was analyzed due to eg an empty
compilation database.
Fixes Ericsson#4222
@noraz31 noraz31 requested review from bruntib and vodorok as code owners April 23, 2024 10:05
@Szelethus
Copy link
Contributor

The implementation is correct, but I whether we went far enough. When is analyzing an empty database desirable? Can we not emit an error with return code 1?

@whisperity whisperity added enhancement 🌟 analyzer 📈 Related to the analyze commands (analysis driver) labels Apr 23, 2024
@bruntib
Copy link
Contributor

bruntib commented Apr 23, 2024

In case of incremental analysis in could be valid providing an empty compilation database.
Also, in case of commits where a module is changed, but the analysis of the module itself is skipped.

@Szelethus
Copy link
Contributor

Very well. I suppose we could emit an error when the input json is technically empty, but not at this point.

@Szelethus Szelethus merged commit 11554c6 into Ericsson:master Apr 24, 2024
8 checks passed
@whisperity whisperity added this to the release 6.24.0 milestone Apr 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
analyzer 📈 Related to the analyze commands (analysis driver) enhancement 🌟
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CodeChecker analyze should warn if the compilation datbase is empty
4 participants