Skip to main content

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

vicalerts-0.3.0.tar.gz (23.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

vicalerts-0.3.0-py3-none-any.whl (18.0 kB view details)

Uploaded Python 3

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

Hashes for vicalerts-0.3.0.tar.gz
Algorithm Hash digest
SHA256 096d3a1339f392e3ac9c8c7e5169f7789dfeffdd64b099d36a211a1d4904eb80
MD5 7d985e815fa57908a319fa2afc66d0a0
BLAKE2b-256 3e23906996a87a28808983d8cea6621ef6031d1fcc737d12cfbcbc8f38fbb266

See more details on using hashes here.

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

Hashes for vicalerts-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c13efe25c1c9b6df6e88c81bf54dfa795d0a88c15faff7ba64d1dfec56f2ac25
MD5 821ab16cd8bb5f5503605299e9a2b7f6
BLAKE2b-256 d05bc530e596640b59c214106f84acfb795fb1bc30eb313af9cde4d2700520e6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page