It's not ready to merge as it stands. Three problems block it: failures are hidden from cron, every customer's email address is written to the logs, and the test file the docstring mentions isn't in the folder. Each one is a small fix, so tomorrow is still realistic if you make them today.

I reviewed `export_job.py` against the standards in your CLAUDE.md. I didn't run anything, because there are no tests to run.

## Blocking

**1. A failed export still looks like success to cron (High)**
At `export_job.py:56-57`, `run()` catches every exception, logs one line and returns normally, so the process exits with code 0.
- **Example:** the finance endpoint returns a 500. `raise_for_status()` raises, the error is logged, and the script exits 0. Cron and any monitoring record a successful run, and finance gets no file. Nobody finds out until finance asks.
- **Expected:** the exit code is non-zero so the failure triggers an alert.
- **Fix:** use `log.exception(...)`, which also records the traceback that `log.error` currently drops, then re-raise.

**2. Every customer email address goes into the logs each night (High, privacy)**
`export_job.py:52` logs `[row[1] for row in rows]`, and `row[1]` is `customer_email`. Log files are usually kept longer and seen by more people than the database. Log the count only.

**3. The tests aren't here (High under your standards)**
The docstring says the job is tested by `test_export_job.py`, but that file isn't in this directory. Even as described ("CSV header and one row"), it would leave most behaviour untested. At minimum the tests should cover:
- an upload failure, which must exit non-zero
- a day with zero invoices
- the date window boundaries (an invoice paid at exactly midnight)
- how amounts are formatted

One thing gets in the way of testing: `UPLOAD_URL = os.environ[...]` on line 16 runs when the file is imported. Importing the module without that variable set raises `KeyError`. Read it inside `upload()`, or pass it in.

## Should fix (could follow in a separate change, but name it as debt)

**4. No timeout on the upload (Medium)**
`requests.post` on line 42 has no `timeout`, so if the endpoint stops responding, the cron job hangs indefinitely. Add something like `timeout=60`.

**5. Amounts are converted to decimals with float division and a hard-coded 100 (Medium)**
Line 37 computes `amount_cents / 100`, which assumes every currency has two decimal places.
- **Example:** 500 JPY (a currency with no minor unit) is exported as `5.0`. 1000 cents is exported as `10.0` rather than `10.00`.
- **Fix:** use `Decimal` with the right number of decimal places per currency, or export the integer cents and let finance convert.
- **Caveat:** this only matters for amounts if you invoice in currencies other than two-decimal ones. Check with finance which format they parse.

**6. Server time and database time may disagree about what "yesterday" means (Medium, depends on your config)**
`date.today()` on line 47 uses the server's local timezone. A plain date compared with `paid_at` is interpreted in the database session's timezone. If those differ, or don't match the timezone finance means by "a day", invoices paid near midnight are exported on the wrong day or missed entirely. Pick a timezone explicitly and test the boundary.

**7. No way to re-run a missed day (Low-Medium)**
The day is always computed as yesterday inside `run()`, so after a failed night someone has to edit code to backfill it. Accept an optional date argument instead.

## Minor
- **Local files are never deleted (Low):** the CSVs with customer emails stay in `/var/exports` indefinitely. Consider a retention policy.
- **Structure:** the split into fetch, write and upload functions is clean and easy to test once item 3's import issue is fixed.

The smallest set of changes that makes this mergeable is items 1–3 plus the timeout (item 4). Each is a few lines plus its tests.

VERDICT: NOT READY
