`export_job.py` is not ready to merge tomorrow as written: a failed export is invisible, and nothing lets you recover the missed day. The must-fix items are small, about half a day of work including tests.

This review is from reading the code only; I ran nothing. `test_export_job.py`, which the docstring cites, is not in this folder, so I could not check what it covers.

## Must fix before merge

1. **Failures are swallowed — High.** `run()` catches every exception, logs one line and exits with code 0 (`export_job.py:56-57`).
   - Case: the finance endpoint returns 500. Cron records success, finance gets no file, and no alert fires. Expected: non-zero exit with a full traceback.
   - Fix: use `log.exception` and re-raise, or `sys.exit(1)`.

2. **No way to re-run a missed day — High.** The date is hard-coded to yesterday (`export_job.py:47`).
   - Case: Tuesday's 02:00 run fails. By Wednesday the job exports only Tuesday's invoices, so Monday's are never sent unless someone edits the code.
   - Fix: accept an optional `--date` argument.

3. **Upload has no timeout — High.** `requests.post` at `export_job.py:42` waits forever by default.
   - Case: the finance endpoint accepts the connection and stalls. The job hangs holding its database connection, and the next night's run starts alongside it.
   - Fix: `timeout=(10, 120)`, or whatever limits suit the endpoint.

4. **Customer emails are written to the log — High (privacy).** `export_job.py:52` logs every customer's email address.
   - Case: 5,000 paid invoices produce one log line with 5,000 email addresses. Expected: only the count and the date.
   - The script never configures logging, so run directly from cron this line is currently dropped. It starts leaking as soon as anyone adds a log handler.

5. **Tests cover only the CSV header and one row — High by your standards.** Per the docstring, nothing tests the date window, upload failure, the error path in `run()`, or a day with zero invoices. Items 1–3 should each land with a test.

## Should fix, can follow shortly after

6. **The job leaves no success record — Medium.** There is no `logging.basicConfig`, so both `log.info` lines are discarded when cron runs the script. Only the "export failed" line reaches stderr, and you cannot confirm from logs that a night's export happened.

7. **"Yesterday" depends on the server's time zone — Medium.** `date.today()` uses server local time, and the database turns the date into midnight in its own session time zone.
   - Case: server on UTC, finance on US Eastern. An invoice paid at 21:00 Eastern on the 13th is 02:00 UTC on the 14th, so it lands in the file for the 14th. Expected: the file for the 13th.
   - Fix: build explicit timezone-aware boundaries in the zone finance uses.

8. **Amounts are formatted inconsistently — Medium.** `amount_cents / 100` at `export_job.py:37` produces a float.
   - Case: 1000 cents is written as `10.0` and 1050 as `10.5`. Expected: `10.00` and `10.50`.
   - Zero-decimal currencies are also wrong if they are stored in whole units: 500 JPY would be written as `5.0`.
   - Fix: format with `Decimal`, or integer division and remainder.

9. **Export files with customer emails pile up — Medium.** Files in `/var/exports` are never deleted and get default permissions. A crash mid-write leaves a partial file under the final name. Write to a temp file, rename, and delete after a successful upload or on a retention schedule.

10. **Upload sends no credentials — Medium, unverified.** No auth header is sent at `export_job.py:42`. If the token is not embedded in `FINANCE_UPLOAD_URL`, the endpoint accepts customer data unauthenticated; please confirm.

## Low severity

11. **Importing the module requires `FINANCE_UPLOAD_URL`.** It is read at import time (`export_job.py:16`), so any test or tool importing the module without it gets a `KeyError`. Read it inside `upload()` or `run()`, as is done for `DATABASE_URL`.

12. **Database connection failure is handled differently from other failures.** `psycopg2.connect` sits outside the `try` (`export_job.py:49`), so it crashes with a traceback while everything else is swallowed. Fixing item 1 makes this consistent.

13. **Spreadsheet formula injection.** An email starting with `=`, `+`, `-` or `@` runs as a formula if finance opens the CSV in Excel. Prefix such values with `'`.

14. **A re-run uploads the same day twice.** Whether that duplicates data depends on the finance endpoint; worth confirming once item 2 adds re-runs.

15. **All rows are loaded into memory.** `fetchall()` is fine at daily volumes; noted only for completeness.

VERDICT: NOT READY
