Skip to main content

Server for [Dinary - your dinar diary](https://github.com/andgineer/dinary). Track expenses, scan receipts, analyze spending with AI

Project description

Build Status Coverage

Dinary

Track expenses, scan receipts, analyze spending with AI

Documentation

Dinary

Local development

Install uv, then:

uv sync

# Create .deploy/.env from the template (one-time, .deploy/ is gitignored)
cp -r .deploy.example .deploy

# First time — or whenever you want a clean slate:
#   wipes data/dinary.db (and the WAL/SHM sidecars), runs schema migrations, seeds the
#   hardcoded 3D taxonomy (groups / categories / events / tags), then
#   starts uvicorn on http://127.0.0.1:8000 with auto-reload.
uv run inv dev --reset

# Subsequent runs — DB is preserved, migrations still apply on startup
# via the FastAPI lifespan, so editing a migration and restarting is
# enough (no separate ``inv migrate`` needed for the local DB):
uv run inv dev

inv dev disables Google-Sheets logging by default so test expenses you create while debugging don't leak into the prod logging spreadsheet (the env var from .deploy/.env is overridden just for this process). Pass --sheet-logging if you specifically want to exercise the drain loop end-to-end.

To point local dev at a copy of prod data instead of an empty DB:

uv run inv backup                         # snapshot prod into ~/Library/dinary/<ts>/
cp ~/Library/dinary/<ts>/data/dinary.db data/
uv run inv dev                            # NOT --reset; keep the snapshot

Credentials are read from ~/.config/gspread/service_account.json (standard gspread location). Don't have a service account key yet? See Google Sheets Setup.

Run tests

inv test

Pre-commit hooks

Use pre-commit for code quality:

pre-commit install

Scripts

Install invoke preferably with uv tool:

uv tool install invoke

For a list of available scripts run:

invoke --list

Deploy to Oracle Cloud

Configure .deploy/.env (see .deploy.example/.env), then:

inv setup-server    # one-time: install deps, clone, create systemd services, upload creds
inv deploy          # pull latest code and restart
inv status --remote # check service status
inv logs --remote   # tail server logs

See Oracle Cloud deployment guide for details.

Reports

Created with cookiecutter using template

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

dinary-0.5.0.tar.gz (905.7 kB view details)

Uploaded Source

Built Distribution

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

dinary-0.5.0-py3-none-any.whl (177.2 kB view details)

Uploaded Python 3

File details

Details for the file dinary-0.5.0.tar.gz.

File metadata

  • Download URL: dinary-0.5.0.tar.gz
  • Upload date:
  • Size: 905.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for dinary-0.5.0.tar.gz
Algorithm Hash digest
SHA256 fbea48e678eccc1e58bb65d29b24e615aaf6ad03f6c69e0226afdc0538b43c27
MD5 97b5f59cf42ecf794b23ca1756928dfb
BLAKE2b-256 4d37fdb09bb45e583c50164441dd80ee6e49a5b94b7c86a78e0ca49e64375f15

See more details on using hashes here.

File details

Details for the file dinary-0.5.0-py3-none-any.whl.

File metadata

  • Download URL: dinary-0.5.0-py3-none-any.whl
  • Upload date:
  • Size: 177.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for dinary-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7404b2f44b63d800543a8d225584d64933dee6300419d19f1ce4d9638e5f251d
MD5 21fbc200dbbff946eabde9292fea85cd
BLAKE2b-256 dc8ec501318b9128b8598665bbff1f0fbac77a640638ea31950e608a308b0603

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