`export_job.py` is not ready to merge tomorrow. It has three high-severity problems, and the test file its docstring names doesn't exist. I only read the code; I didn't run it, and I couldn't check the database schema or the finance endpoint's contract.

## High severity

1. **Failures are swallowed, so cron will never see them (`export_job.py:56-57`).** `except Exception` logs the error and then the script exits with code 0.
   - Example: the finance endpoint returns a 500 at 02:00. `raise_for_status()` raises, the error is logged, and cron reports success. Finance never gets that day's invoices, and nobody is alerted.
   - Fix: re-raise after logging, or call `sys.exit(1)`.

2. **Customer emails are written to the logs (`export_job.py:52`).** Every nightly run logs the full list of customer emails for the day, which is personal data. Log the count and the date only.

3. **The money amount is converted incorrectly (`export_job.py:37`).** `amount_cents / 100` is a float.
   - Example: 100000 cents is written as `1000.0`, not `1000.00`. Floats can also produce odd values for other amounts.
   - Fix: use `Decimal(amount_cents) / 100` formatted to two decimal places, or write `f"{amount_cents // 100}.{amount_cents % 100:02d}"`.
   - Finance may be importing this file, so confirm the format they expect.

## Medium severity

4. **The "yesterday" window uses the server's local date and ignores time zones (`export_job.py:47`, `export_job.py:28`).** `date.today()` uses the server's local time zone. The query compares `paid_at` to bare dates. If `paid_at` is a UTC `timestamptz` and the server isn't on UTC, invoices near midnight land in the wrong day's file. Decide which zone defines a "day" and apply it explicitly.

5. **There are no tests.** The docstring says `test_export_job.py` covers the CSV header and one row, but that file isn't in this directory. Even if it exists elsewhere, that coverage wouldn't catch the problems above. Tests I'd want before merging:
   - Failed upload gives a non-zero exit.
   - Amounts are formatted correctly (100000 → `1000.00`).
   - The day boundary: 23:59:59 yesterday is included and 00:00:00 today is excluded.
   - Zero invoices.

6. **Re-running the job can upload duplicates.** There is no idempotency or retry handling. A failed run that gets re-run will upload twice unless the endpoint deduplicates. At minimum, say how the endpoint handles repeat uploads.

## Low severity

7. `UPLOAD_URL = os.environ["FINANCE_UPLOAD_URL"]` runs at import time. A missing variable raises a `KeyError` on import, which makes the module hard to test. Read it inside `run()` instead.
8. `requests.post` has no timeout (`export_job.py:42`), so a hung endpoint blocks the cron job forever. Add `timeout=30`.
9. The `/var/exports` directory is hard-coded and never created. Make it configurable and create it if missing.
10. The exported CSV files are never cleaned up. That's a minor disk-growth concern.
11. `run()` handles the query, file writing, upload and logging in one function. That's acceptable at this size, but it will be harder to test once the fixes above go in.

Given the deadline, items 1–3 plus the tests for them are the minimum. Items 4 and 6 need a decision from you or finance, even if the fix itself is small. Items 7–11 can be logged as follow-up debt.

VERDICT: NOT READY
