Skip to content

Commit 9ba670f

Browse files
authored
Merge pull request #2218 from Kobzol/site-empty-results
Do not exit website if there is no data
2 parents 563cc7d + d7b43d7 commit 9ba670f

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -333,12 +333,12 @@ jobs:
333333
- name: Connect to PostgreSQL
334334
run: |
335335
timeout 5s ./target/debug/site 'postgresql://postgres:postgres@localhost:5432/postgres' 2>&1 | tee -a log || true
336-
grep -Fxq "Loading complete but no data identified; exiting." log
336+
grep -Fxq "Warning: loading complete but no data identified." log
337337
338338
- name: Connect to SQLite
339339
run: |
340340
timeout 5s ./target/debug/site 2>&1 | tee -a log || true
341-
grep -Fxq "Loading complete but no data identified; exiting." log
341+
grep -Fxq "Warning: loading complete but no data identified." log
342342
343343
- name: Build Postgres to SQLite exporter
344344
run: cargo build --bin postgres-to-sqlite

site/src/main.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,7 @@ async fn main() {
4242
let commits = res.index.load().commits().len();
4343
let artifacts = res.index.load().artifacts().count();
4444
if commits + artifacts == 0 {
45-
eprintln!("Loading complete but no data identified; exiting.");
46-
std::process::exit(1);
45+
eprintln!("Warning: loading complete but no data identified.");
4746
}
4847
eprintln!("Loading complete; found {} artifacts", commits + artifacts);
4948
eprintln!(

0 commit comments

Comments
 (0)