Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
47fab24
docs: add Phase 0 audit of data provenance, dependencies, and defects
gavinrozzi Aug 24, 2026
55c5e99
test: add regression tests for zip_distance input ordering (#20)
gavinrozzi Aug 24, 2026
ca64595
fix: vectorize reverse_zipcode and geocode_zip preserving input order…
gavinrozzi Aug 24, 2026
5357c4b
refactor: replace raster with internal haversine distance (#21, #24, …
gavinrozzi Aug 24, 2026
ed9ec12
refactor: vendor Census FIPS table, drop tidycensus (#21, #24, #28)
gavinrozzi Aug 24, 2026
71951ee
refactor: drop tidyr, demote download-only deps to Suggests
gavinrozzi Aug 24, 2026
e0633aa
docs: add FAQ vignette; document data provenance and limitations (#13…
gavinrozzi Aug 24, 2026
3457e1e
ci: modernize GitHub Actions workflows to r-lib/actions v2
gavinrozzi Aug 24, 2026
e16e736
chore: bump version to 0.4.0, update NEWS, migrate CITATION to bibent…
gavinrozzi Aug 24, 2026
a50bf93
docs: stage draft issue comments for maintainer review
gavinrozzi Aug 24, 2026
aaf1fa4
docs: update README links to relocated documentation site
gavinrozzi Aug 24, 2026
bc25cf7
feat: add reproducible data pipeline under data-raw/
gavinrozzi Aug 24, 2026
4c6dec9
feat: add zip_data_version() and download_comprehensive_data()
gavinrozzi Aug 24, 2026
0d3bd81
data: refresh all datasets via the pipeline (#19, #25, #26, #29)
gavinrozzi Aug 24, 2026
6b95a96
ci: add quarterly data-refresh workflow; fix broken pkgdown install step
gavinrozzi Aug 24, 2026
b432d0e
docs: NEWS for the data refresh; stage issue comments for #19/#25/#26…
gavinrozzi Aug 24, 2026
36c6208
docs: update CLAUDE.md dataset counts for the refreshed data
gavinrozzi Aug 24, 2026
b8e3be8
fix: declare openssl in Suggests for the sha256 fallback
gavinrozzi Aug 24, 2026
2cf2727
perf: bounding-box prefilter for search_radius; input validation; sch…
gavinrozzi Aug 24, 2026
a8f3bc3
docs: add ROADMAP.md with release plan and standing policies
gavinrozzi Aug 24, 2026
92ea3b7
ci: install the preferably pkgdown template from GitHub
gavinrozzi Aug 24, 2026
071ba68
fix: address code-review findings across search_radius, zip_to_cd, an…
gavinrozzi Aug 24, 2026
a8a3b7a
fix: address second-round review findings
gavinrozzi Aug 24, 2026
9d3bd89
fix: address third-round review findings
gavinrozzi Aug 24, 2026
93aeeba
fix: address fourth-round review findings
gavinrozzi Aug 24, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,9 @@ paper.pdf$
^codecov\.yml$
^README\.Rmd$
^CRAN-SUBMISSION$
^data-raw$
^AUDIT\.md$
^CLAUDE\.md$
^issue_comments$
^bench$
^ROADMAP\.md$
80 changes: 23 additions & 57 deletions .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
@@ -1,17 +1,14 @@
# For help debugging build failures open an issue on the RStudio community with the 'github-actions' tag.
# https://community.rstudio.com/new-topic?category=Package%20development&tags=github-actions
# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples
on:
push:
branches:
- main
- master
branches: [main, master]
pull_request:
branches:
- main
- master
branches: [main, master]

name: R-CMD-check

permissions: read-all

jobs:
R-CMD-check:
runs-on: ${{ matrix.config.os }}
Expand All @@ -22,65 +19,34 @@ jobs:
fail-fast: false
matrix:
config:
- {os: macos-latest, r: 'release'}
- {os: windows-latest, r: 'release'}
- {os: macOS-latest, r: 'release'}
- {os: ubuntu-20.04, r: 'release', rspm: "https://packagemanager.rstudio.com/cran/__linux__/focal/latest"}
- {os: ubuntu-20.04, r: 'devel', rspm: "https://packagemanager.rstudio.com/cran/__linux__/focal/latest"}
- {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'}
- {os: ubuntu-latest, r: 'release'}
- {os: ubuntu-latest, r: 'oldrel-1'}

env:
R_REMOTES_NO_ERRORS_FROM_WARNINGS: true
RSPM: ${{ matrix.config.rspm }}
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
R_KEEP_PKG_SOURCE: yes

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4

- uses: r-lib/actions/setup-pandoc@v2

- uses: r-lib/actions/setup-r@v1
- uses: r-lib/actions/setup-r@v2
with:
r-version: ${{ matrix.config.r }}
http-user-agent: ${{ matrix.config.http-user-agent }}
use-public-rspm: true

- uses: r-lib/actions/setup-pandoc@v1

- name: Query dependencies
run: |
install.packages('remotes')
saveRDS(remotes::dev_package_deps(dependencies = TRUE), ".github/depends.Rds", version = 2)
writeLines(sprintf("R-%i.%i", getRversion()$major, getRversion()$minor), ".github/R-version")
shell: Rscript {0}

- name: Restore R package cache
if: runner.os != 'Windows'
uses: actions/cache@v2
- uses: r-lib/actions/setup-r-dependencies@v2
with:
path: ${{ env.R_LIBS_USER }}
key: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-1-${{ hashFiles('.github/depends.Rds') }}
restore-keys: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-1-

- name: Install system dependencies
if: runner.os == 'Linux'
run: |
while read -r cmd
do
eval sudo $cmd
done < <(Rscript -e 'writeLines(remotes::system_requirements("ubuntu", "20.04"))')

- name: Install dependencies
run: |
remotes::install_deps(dependencies = TRUE)
remotes::install_cran("rcmdcheck")
shell: Rscript {0}

- name: Check
env:
_R_CHECK_CRAN_INCOMING_REMOTE_: false
run: |
options(crayon.enabled = TRUE)
rcmdcheck::rcmdcheck(args = c("--no-manual", "--as-cran"), error_on = "warning", check_dir = "check")
shell: Rscript {0}
extra-packages: any::rcmdcheck
needs: check

- name: Upload check results
if: failure()
uses: actions/upload-artifact@main
- uses: r-lib/actions/check-r-package@v2
with:
name: ${{ runner.os }}-r${{ matrix.config.r }}-results
path: check
args: 'c("--no-manual", "--as-cran")'
upload-snapshots: true
build_args: 'c("--no-manual", "--compact-vignettes=gs+qpdf")'
8 changes: 2 additions & 6 deletions .github/workflows/pkgdown.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,9 @@ jobs:

- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::pkgdown, local::.
# the preferably pkgdown template is no longer on CRAN; install from GitHub
extra-packages: any::pkgdown, github::amirmasoudabdol/preferably, local::.
needs: website

- name: Install dependencies
run: |
remotes::install_deps(dependencies = TRUE)
install.packages(c("pkgdown","preferably"), type = "binary")

- name: Build site
run: pkgdown::build_site_github_pages(new_process = FALSE, install = FALSE)
Expand Down
66 changes: 66 additions & 0 deletions .github/workflows/refresh-data.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
# Quarterly + on-demand data refresh. Runs the data-raw/ pipeline, which
# hard-fails unless the validation gate passes, then opens a PR with the
# refresh summary. A human reviews and merges; nothing ships automatically.
#
# Requirements: repository secret CENSUS_API_KEY (free key from
# https://api.census.gov/data/key_signup.html).
#
# Runner note: this is a single lightweight job (~10 min, ~2 GB disk). To run
# it on the self-hosted runner instead of hosted minutes, change `runs-on:`
# to [self-hosted] — the job needs only R >= 4.2, curl, and network access.

on:
workflow_dispatch:
schedule:
- cron: '17 6 1 2,5,8,11 *' # 06:17 UTC on the 1st of Feb/May/Aug/Nov

name: refresh-data

permissions:
contents: write
pull-requests: write

jobs:
refresh-data:
runs-on: ubuntu-latest
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
CENSUS_API_KEY: ${{ secrets.CENSUS_API_KEY }}

steps:
- uses: actions/checkout@v4

- uses: r-lib/actions/setup-r@v2
with:
use-public-rspm: true

- uses: r-lib/actions/setup-r-dependencies@v2
with:
packages: |
any::dplyr
any::DBI
any::RSQLite
any::jsonlite
install-package: false

- name: Cache pipeline sources
uses: actions/cache@v4
with:
path: data-raw/cache
key: data-sources-${{ hashFiles('data-raw/sources.R') }}

- name: Run data pipeline (includes validation gate)
run: Rscript data-raw/run_pipeline.R

- name: Open data refresh PR
uses: peter-evans/create-pull-request@v6
with:
branch: data-refresh
commit-message: 'data: scheduled refresh via data-raw pipeline'
title: 'Data refresh (validation gate passed)'
body-path: data-raw/refresh_summary.md
add-paths: |
data/
R/sysdata.rda
data-raw/refresh_summary.md
draft: true
55 changes: 55 additions & 0 deletions .github/workflows/test-coverage.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples
on:
push:
branches: [main, master]
pull_request:
branches: [main, master]

name: test-coverage

permissions: read-all

jobs:
test-coverage:
runs-on: ubuntu-latest
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}

steps:
- uses: actions/checkout@v4

- uses: r-lib/actions/setup-r@v2
with:
use-public-rspm: true

- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::covr, any::xml2
needs: coverage

- name: Test coverage
run: |
cov <- covr::package_coverage(
quiet = FALSE,
clean = FALSE,
install_path = file.path(normalizePath(Sys.getenv("RUNNER_TEMP"), winslash = "/"), "package")
)
print(cov)
covr::to_cobertura(cov)
shell: Rscript {0}

- uses: codecov/codecov-action@v4
with:
# 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 }}
files: ./cobertura.xml
plugins: noop
disable_search: true
token: ${{ secrets.CODECOV_TOKEN }}

- name: Show testthat output
if: always()
run: |
## --------------------------------------------------------------------
find '${{ runner.temp }}/package' -name 'testthat.Rout*' -exec cat '{}' \; || true
shell: bash
Loading
Loading