**Not mergeable as it stands, but it can be merged tomorrow if you make four small fixes first.** The structure is fine; the problems are in failure handling, logging and test coverage. I read only `export_job.py` and ran nothing, so the test coverage comment relies on the file's docstring.

## Must fix before merge

1. **A failed export looks like a success to cron** (`export_job.py:56-57`). `run()` catches every exception, logs one line and exits with code 0.
   - **Failing case:** the finance endpoint returns 503 at 02:00. The only trace is one "export failed" line with no traceback, the job exits 0, and finance gets no file.
   - **Expected:** a non-zero exit so cron or monitoring alerts.
   - **Fix:** use `log.exception(...)` and re-raise, or `sys.exit(1)`.

2. **Customer emails are written to the log** (`export_job.py:52`). The info line logs every customer's email address for the day. Log the count and date only.

3. **The upload has no timeout** (`export_job.py:42`). If the finance endpoint accepts the connection and then stalls, `requests.post` waits forever, holding the database connection open. Add `timeout=(10, 120)` or similar.

4. **Tests cover only the CSV header and one row.** By your own standard this is not done. I would add at least:
   - a test of the date window in `fetch_invoices`;
   - a test that `upload` raises on a non-2xx response;
   - a test that `run` exits non-zero on failure;
   - a test of the empty-day case.

## Should fix, or confirm it is intended

- **A missed day cannot be re-run.** The date is hard-coded to yesterday (`export_job.py:47`). If Tuesday's run fails, Tuesday's invoices are never exported unless someone edits the code. Accept an optional date argument.
- **"Yesterday" depends on two clocks.** `date.today()` uses the cron host's timezone, while the `paid_at` comparison uses the database session's timezone. If they differ, invoices near midnight land in the wrong day's file. Check what type `paid_at` is and pin the timezone explicitly.
- **Amount formatting is inconsistent** (`export_job.py:37`). `amount_cents / 100` gives a float, so 1990 cents is written as `19.9` and 2000 as `20.0`. Use `f"{amount_cents / 100:.2f}"` or `Decimal`.
- **Dividing by 100 may be wrong for some currencies.** If you bill in currencies without cents, such as JPY, the amounts will be 100 times too small.
- **Success is never recorded.** The script never configures logging, so the two `log.info` lines are dropped when it is run directly. Add `logging.basicConfig(level=logging.INFO)` under `__main__`, after fixing the email logging.
- **The module cannot be imported without `FINANCE_UPLOAD_URL` set** (`export_job.py:16`). This makes tests awkward. Read it inside `upload()` or pass it in.

## Minor

- **Files pile up.** CSVs containing customer emails accumulate in `/var/exports` with no cleanup, and a failed run leaves a partial file behind.
- **Spreadsheet formulas.** If finance opens the file in Excel, an email starting with `=` or `+` is treated as a formula.
- **Empty days.** A day with zero invoices uploads a header-only file. That is probably fine, but confirm finance expects it.

VERDICT: READY WITH CHANGES
