**Not ready to merge tomorrow.** `run()` hides every failure, so a broken export would look like a successful one. Customer emails also go into the logs. Both fixes are small. I only read `export_job.py`; I didn't open `test_export_job.py` or run anything. The docstring says that file covers just the CSV header and one row.

## Blockers

1. **All failures are swallowed (`export_job.py:56-57`).**
   - `except Exception` logs the error and then returns normally, so the process exits 0.
   - Example: the finance endpoint returns a 500 at 02:00. `raise_for_status()` raises, the job logs one line, and cron records a success. Finance never gets the file, and nothing alerts anyone.
   - Fix: re-raise after logging, or call `sys.exit(1)`, so cron and your monitoring see the failure.

2. **Customer emails are logged (`export_job.py:52`).**
   - The log line prints `[row[1] for row in rows]`, which is every customer email for the day, at INFO level.
   - Personal data ends up in log storage with different access and retention rules than the finance export. For a typical day this is also a very long line.
   - Fix: log only the count and the date.

## Should fix before merge (medium)

3. **Money is formatted as a float (`export_job.py:37`).**
   - `amount_cents / 100` produces floats. 100000 cents is written as `1000.0`, and 1999 cents is `19.99`. The format is inconsistent, and float representation can break exact reconciliation.
   - Fix: use `Decimal(amount_cents) / 100` and format with two decimals, or keep the column in cents.

4. **The "yesterday" window is timezone-ambiguous (`export_job.py:47`, `export_job.py:21`).**
   - `date.today()` uses the cron host's timezone. A bare date compared against `paid_at` is interpreted in the database session's timezone.
   - If those differ, invoices paid near midnight land in the wrong day's file, or in none.
   - Fix: pick one timezone (probably UTC) and build explicit timezone-aware bounds.

5. **No timeout on the upload (`export_job.py:42`).**
   - `requests.post` with no `timeout` can hang forever if the endpoint stalls. A hung 02:00 job never reports anything, and runs can pile up.
   - Fix: add `timeout=`.

6. **Test coverage is thin.**
   - The tests exercise only `write_csv`. Nothing covers `fetch_invoices`, `upload`, an empty day, or failure behavior.
   - Fixing #1 needs a regression test: when the upload fails, `run()` raises or exits non-zero.
   - Fix: add that test along with a few for the other paths. With mocked `requests` and an in-memory connection fake they're quick to write.

## Minor (can follow up, but note the debt)

7. **`UPLOAD_URL = os.environ[...]` runs at import time (`export_job.py:16`).** Importing the module without the variable set raises `KeyError`, which makes tests awkward. Read it inside `run()` or `upload()`.
8. **The CSV with customer emails is left in `/var/exports` with default file permissions (`export_job.py:33`).** Set restrictive permissions, or delete the file after a successful upload.
9. **CSV formula injection.** An email beginning with `=` or `+` would be interpreted as a formula if finance opens the file in Excel. Low risk, but cheap to guard against.
10. **Empty days upload a header-only file, and there is no retry.** Check that finance expects the empty file. A single retry on upload would help with transient network errors.
11. **`fetchall()` loads the whole day into memory.** That's fine at current volume. Revisit if volume grows.

## Recommendation

Items 1, 2 and 5 are a few lines each. Items 3, 4 and 6 are the ones to add with tests. If the deadline is tight, fix 1, 2, 5 and the failure-path test for 1 now. Ship with 3 and 4 as tracked follow-ups, and say so in the PR so the debt is visible.

VERDICT: NOT READY
