Track & archive Victoria's live emergency alerts
Project description
VicAlerts
Track and archive VicEmergency incidents to a local SQLite database.
Purpose
VicAlerts polls the public VicEmergency GeoJSON feed, stores every version of every event, and exposes a small CLI for querying the result. Useful for incident timelines, post-event analysis, or keeping your own history for when events expire from the feed. It is designed to run 24/7 to collect data.
Installation
uv pip install vicalerts
Requires Python 3.10 or newer.
Quick start
# Continuous polling (60 s default)
vicalerts run
# One-off fetch (handy in cron)
vicalerts run --once
CLI reference
| Command | Description | Key options |
|---|---|---|
run |
Poll feed and write to the DB | --once, --interval <seconds> (>=10), --db <path>, --no-progress |
events |
List events (active only by default) | --all, --type incident|warning, --status <text>, --category <text>, --limit <n>, --format table|json|csv, --db <path> |
history <EVENT_ID> |
Show full version history | --db <path> |
stats |
Print DB totals | --db <path> |
All commands accept --help.
Defaults
| Setting | Value |
|---|---|
| Feed URL | https://emergency.vic.gov.au/public/events-geojson.json |
| Interval | 60 s |
| HTTP timeout | 30 s |
| Retries | 3 (1 s, then 2 s, then 4 s) |
| Database | ./vicalerts.sqlite |
Example workflows
# 1. Nightly stats
vicalerts stats --db /data/vic.sqlite
# 2. Export active incidents as JSON
vicalerts events --type incident --format json > incidents.json
# 3. Inspect how an event evolved
vicalerts history 123456 --db /data/vic.sqlite
Notes and limitations
- Disk growth is roughly 10–20 MB per month (feeds are compressed).
- Memory use is modest (< 50 MB typical).
- Geometry is reduced to centroids; polygons are not preserved.
- Tested on Linux and macOS; Windows untested.
- 60s interval is based on VicEmergency website; impact is no different to having the site open.
Attribution
Data © State of Victoria (EMV) - data licensed under CC BY 4.0 AU
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file vicalerts-0.3.0.tar.gz.
File metadata
- Download URL: vicalerts-0.3.0.tar.gz
- Upload date:
- Size: 23.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
096d3a1339f392e3ac9c8c7e5169f7789dfeffdd64b099d36a211a1d4904eb80
|
|
| MD5 |
7d985e815fa57908a319fa2afc66d0a0
|
|
| BLAKE2b-256 |
3e23906996a87a28808983d8cea6621ef6031d1fcc737d12cfbcbc8f38fbb266
|
File details
Details for the file vicalerts-0.3.0-py3-none-any.whl.
File metadata
- Download URL: vicalerts-0.3.0-py3-none-any.whl
- Upload date:
- Size: 18.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c13efe25c1c9b6df6e88c81bf54dfa795d0a88c15faff7ba64d1dfec56f2ac25
|
|
| MD5 |
821ab16cd8bb5f5503605299e9a2b7f6
|
|
| BLAKE2b-256 |
d05bc530e596640b59c214106f84acfb795fb1bc30eb313af9cde4d2700520e6
|