Skip to content

Commit 8fae5bf

Browse files
committed
Add download warning on boot
1 parent 837d95d commit 8fae5bf

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

cpi/__init__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@
2121
this_dir = Path(__file__).parent.absolute()
2222
db_path = this_dir / "cpi.db"
2323
if not db_path.exists():
24+
warnings.warn(
25+
"CPI database not found. Downloading... This may take a few minutes.",
26+
stacklevel=2,
27+
)
2428
logger.info("CPI database not found. Downloading...")
2529
Downloader().update()
2630

0 commit comments

Comments
 (0)