From b00d48d0368f00ef0f46871e921e7f25d59a1763 Mon Sep 17 00:00:00 2001 From: Douglas Ezra Morrison Date: Tue, 7 Jan 2025 22:10:52 -0800 Subject: [PATCH 01/10] attempt to fix codecov error checking --- .github/workflows/test-coverage.yaml | 3 ++- README.md | 3 ++- README.qmd | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test-coverage.yaml b/.github/workflows/test-coverage.yaml index 45e8c147..e050312f 100644 --- a/.github/workflows/test-coverage.yaml +++ b/.github/workflows/test-coverage.yaml @@ -39,7 +39,8 @@ jobs: - uses: codecov/codecov-action@v4 with: - fail_ci_if_error: ${{ github.event_name != 'pull_request' && true || false }} + # Fail if error if not on PR, or if on PR and token is given + fail_ci_if_error: ${{ github.event_name != 'pull_request' || secrets.CODECOV_TOKEN }} file: ./cobertura.xml plugin: noop disable_search: true diff --git a/README.md b/README.md index 293a0d28..c58a1700 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,8 @@ [![R-CMD-check](https://github.com/UCD-SERG/serocalculator/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/UCD-SERG/serocalculator/actions/workflows/R-CMD-check.yaml) -[![codecov](https://codecov.io/gh/UCD-SERG/serocalculator/graph/badge.svg?token=85CXV6GN2T)](https://codecov.io/gh/UCD-SERG/serocalculator) +[![Codecov test +coverage](https://codecov.io/gh/UCD-SERG/serocalculator/graph/badge.svg)](https://app.codecov.io/gh/UCD-SERG/serocalculator)
diff --git a/README.qmd b/README.qmd index 67b1e0df..7f1352c3 100644 --- a/README.qmd +++ b/README.qmd @@ -18,7 +18,7 @@ knitr::opts_chunk$set( [![R-CMD-check](https://github.com/UCD-SERG/serocalculator/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/UCD-SERG/serocalculator/actions/workflows/R-CMD-check.yaml) -[![codecov](https://codecov.io/gh/UCD-SERG/serocalculator/graph/badge.svg?token=85CXV6GN2T)](https://codecov.io/gh/UCD-SERG/serocalculator) +[![Codecov test coverage](https://codecov.io/gh/UCD-SERG/serocalculator/graph/badge.svg)](https://app.codecov.io/gh/UCD-SERG/serocalculator) ```{r svg} From 360bfbf0699a4802829c974894dc87555462d3fc Mon Sep 17 00:00:00 2001 From: Douglas Ezra Morrison Date: Tue, 7 Jan 2025 22:11:25 -0800 Subject: [PATCH 02/10] Increment version number to 1.2.0.9024 --- DESCRIPTION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DESCRIPTION b/DESCRIPTION index 2069a351..c6b3cc82 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,7 +1,7 @@ Type: Package Package: serocalculator Title: Estimating Infection Rates from Serological Data -Version: 1.2.0.9023 +Version: 1.2.0.9024 Authors@R: c( person("Peter", "Teunis", , "p.teunis@emory.edu", role = c("aut", "cph"), comment = "Author of the method and original code."), From 67a979ed43f2dd84cd7eebb17ece3db78edfb3bb Mon Sep 17 00:00:00 2001 From: Douglas Ezra Morrison Date: Tue, 7 Jan 2025 22:12:38 -0800 Subject: [PATCH 03/10] more --- NEWS.md | 3 +++ inst/WORDLIST | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/NEWS.md b/NEWS.md index ecb644c6..494b8ad7 100644 --- a/NEWS.md +++ b/NEWS.md @@ -28,6 +28,9 @@ (from ) (#265) ## Internal changes + +* Updated `test-coverage.yml` GHA action to current `r-lib` standard. + * Change default pipe setting (#312) * Add test for missing strata in `est.incidence.by` (#227) diff --git a/inst/WORDLIST b/inst/WORDLIST index ef8029da..af9b4971 100644 --- a/inst/WORDLIST +++ b/inst/WORDLIST @@ -8,6 +8,7 @@ CMD Campylobacter Ceper Chiang +Codecov De Dhulikhel Diekmann @@ -17,6 +18,7 @@ FIC Falkenhorst Fogarty Friesema +GHA Gageldonk Graaf Gras @@ -98,7 +100,6 @@ boldsymbol callout campylobacteriosis cdot -codecov de der devtools From c894b0f0541b49c041972436a972d38c8ece65fd Mon Sep 17 00:00:00 2001 From: Douglas Ezra Morrison Date: Tue, 7 Jan 2025 22:13:19 -0800 Subject: [PATCH 04/10] more --- NEWS.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NEWS.md b/NEWS.md index 494b8ad7..db0fae2b 100644 --- a/NEWS.md +++ b/NEWS.md @@ -29,7 +29,7 @@ ## Internal changes -* Updated `test-coverage.yml` GHA action to current `r-lib` standard. +* Updated `test-coverage.yml` GHA action to current `r-lib` standard (#330) * Change default pipe setting (#312) From 5eba597c45b8df8b634681739efbf32a66e857c9 Mon Sep 17 00:00:00 2001 From: Douglas Ezra Morrison Date: Tue, 7 Jan 2025 22:33:48 -0800 Subject: [PATCH 05/10] trying to trigger test-coverage fail --- R/test-function.R | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 R/test-function.R diff --git a/R/test-function.R b/R/test-function.R new file mode 100644 index 00000000..581cf79b --- /dev/null +++ b/R/test-function.R @@ -0,0 +1,3 @@ +testfn = function() { + 1 + 1 +} From b927e9fe70b54978bed38da21e5ab192e56cbee8 Mon Sep 17 00:00:00 2001 From: Douglas Ezra Morrison Date: Tue, 7 Jan 2025 22:44:00 -0800 Subject: [PATCH 06/10] test --- codecov.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/codecov.yml b/codecov.yml index 6907daec..0684e5cc 100644 --- a/codecov.yml +++ b/codecov.yml @@ -9,6 +9,6 @@ coverage: informational: true patch: default: - target: auto + target: 100% threshold: 1% informational: true From bff1b4d072e1e2e31e3340db0fc3a4d40535ce37 Mon Sep 17 00:00:00 2001 From: Douglas Ezra Morrison Date: Tue, 7 Jan 2025 22:46:58 -0800 Subject: [PATCH 07/10] see https://docs.codecov.com/docs/commit-status#informational --- codecov.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/codecov.yml b/codecov.yml index 0684e5cc..f390aaaf 100644 --- a/codecov.yml +++ b/codecov.yml @@ -6,9 +6,9 @@ coverage: target: auto #default threshold: 1% base: auto - informational: true + informational: false patch: default: - target: 100% + target: auto threshold: 1% - informational: true + informational: false From 0511c0b73d60071421a7926db1c1ff8209ab2af4 Mon Sep 17 00:00:00 2001 From: Douglas Ezra Morrison Date: Tue, 7 Jan 2025 22:49:38 -0800 Subject: [PATCH 08/10] comments --- codecov.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/codecov.yml b/codecov.yml index f390aaaf..fd6f67d0 100644 --- a/codecov.yml +++ b/codecov.yml @@ -1,12 +1,13 @@ coverage: status: - project: #add everything under here, more options at https://docs.codecov.com/docs/commit-status + project: # add everything under here, more options at + # https://docs.codecov.com/docs/commit-status default: # basic - target: auto #default + target: auto # default threshold: 1% base: auto - informational: false + informational: false # default patch: default: target: auto From e6c1ac8000591b8165918a990c35193865618b27 Mon Sep 17 00:00:00 2001 From: Douglas Ezra Morrison Date: Tue, 7 Jan 2025 22:55:46 -0800 Subject: [PATCH 09/10] confirmed that codecov flags noncoverage; deleting test function --- R/test-function.R | 3 --- 1 file changed, 3 deletions(-) delete mode 100644 R/test-function.R diff --git a/R/test-function.R b/R/test-function.R deleted file mode 100644 index 581cf79b..00000000 --- a/R/test-function.R +++ /dev/null @@ -1,3 +0,0 @@ -testfn = function() { - 1 + 1 -} From 7f0cc6f55a9bb580d2c5a91e76c91d981a973940 Mon Sep 17 00:00:00 2001 From: Douglas Ezra Morrison Date: Tue, 7 Jan 2025 22:56:41 -0800 Subject: [PATCH 10/10] not updating version number since actual package hasn't changed, just dev metadata --- DESCRIPTION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DESCRIPTION b/DESCRIPTION index c6b3cc82..2069a351 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,7 +1,7 @@ Type: Package Package: serocalculator Title: Estimating Infection Rates from Serological Data -Version: 1.2.0.9024 +Version: 1.2.0.9023 Authors@R: c( person("Peter", "Teunis", , "p.teunis@emory.edu", role = c("aut", "cph"), comment = "Author of the method and original code."),