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

[c++] Set warnings-as-errors to be off by default #3159

Merged
merged 3 commits into from
Oct 10, 2024

Conversation

jp-dark
Copy link
Collaborator

@jp-dark jp-dark commented Oct 9, 2024

Issue and/or context:
Warnings as errors are useful for developers/CI, but cause unnecessary friction for users. Turn them off by default. See issue #3087.

Changes:

  • Set TILEDBSOMA_ENABLE_WERROR to be OFF by default.
  • Allow user to set TILEDBSOMA_ENABLE_WERROR as an environment variable. This can be overridden by a user provided value.
  • Fix CMake code checking if TILEDBSOMA_ENABLE_WERROR is OFF.
  • Update the build script to take werror as an argument.
  • Explicitly set werror=true for CI.

Copy link

codecov bot commented Oct 9, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 83.30%. Comparing base (46bf2ec) to head (a8dfa1b).
Report is 8 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3159      +/-   ##
==========================================
+ Coverage   82.92%   83.30%   +0.38%     
==========================================
  Files          50       51       +1     
  Lines        5236     5458     +222     
==========================================
+ Hits         4342     4547     +205     
- Misses        894      911      +17     
Flag Coverage Δ
python 83.30% <ø> (+0.38%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
python_api 83.30% <100.00%> (+0.38%) ⬆️
libtiledbsoma ∅ <ø> (∅)

@johnkerl johnkerl changed the title Set warnings as errors to be off by default [c++] Set warnings as errors to be off by default Oct 9, 2024
Copy link
Member

@johnkerl johnkerl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unless I'm missing it we need some way to be sure this flag is always set for devleopers. Maybe some env-var check and we can be sure to all set it in our shell .rc files ...

@jp-dark jp-dark requested a review from johnkerl October 10, 2024 18:07
Copy link
Member

@johnkerl johnkerl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔥

@johnkerl johnkerl changed the title [c++] Set warnings as errors to be off by default [c++] Set warnings-as-errors to be off by default Oct 10, 2024
@jp-dark jp-dark merged commit 21d9e71 into main Oct 10, 2024
35 checks passed
@jp-dark jp-dark deleted the dark/werror-off-by-default branch October 10, 2024 19:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants