|
1 | | -# FX Risk Calculator |
| 1 | +# FX Risk Calculator |
2 | 2 |
|
3 | 3 |  |
4 | 4 |
|
@@ -49,7 +49,7 @@ blueprints. |
49 | 49 | ```bash |
50 | 50 | flask --app app.cli.seed_demo seed-demo |
51 | 51 | ``` |
52 | | - This command is idempotent and will recreate the “Global Book (USD)” sample positions when needed. |
| 52 | + This command is idempotent and will recreate the “Global Book (USD)†sample positions when needed. |
53 | 53 | - Generate a sample portfolio (~2k positions) and verify latency budgets with: |
54 | 54 | ```bash |
55 | 55 | python scripts/perf_sanity_check.py --reset |
@@ -132,7 +132,7 @@ Scheduler uses APScheduler; disable it via `SCHEDULER_ENABLED=false` or adjust c |
132 | 132 | ### Postman Collection |
133 | 133 | - Import `postman/fx-risk-calculator.postman_collection.json` for a curated set of health, portfolio, position, rates, and metrics requests. |
134 | 134 | - Pair it with the environment file `postman/fx-risk-calculator.postman_environment.json` to populate `{{baseUrl}}`, `{{portfolioId}}`, and other reusable variables. |
135 | | -- Run “Create Portfolio” first to set `portfolioId`, then create positions before issuing metrics calls. Use the manual refresh request to pull fresh rates when needed. |
| 135 | +- Run “Create Portfolio†first to set `portfolioId`, then create positions before issuing metrics calls. Use the manual refresh request to pull fresh rates when needed. |
136 | 136 |
|
137 | 137 | ## Portfolio API |
138 | 138 | - `GET /api/v1/portfolios?page=<page>&page_size=<limit>` lists portfolios with pagination metadata. |
@@ -250,15 +250,22 @@ Validation rules: |
250 | 250 |
|
251 | 251 | Use `python scripts/perf_sanity_check.py` to seed a ~2k-position dataset and print latency numbers for the main portfolio metrics endpoints. See `docs/performance.md` for sample output and interpretation guidelines. |
252 | 252 |
|
| 253 | +### Release Checklist |
| 254 | + |
| 255 | +1. `make release-check` ? runs lint, type checks, test suite, and a quick `/health` smoke test. |
| 256 | +2. `flask --app app.cli.seed_demo seed-demo` to pre-load the demo portfolio before recording or demoing. |
| 257 | +3. Start the server (`python run.py`) and verify the dashboard at http://127.0.0.1:5000#/dashboard renders charts with the seeded data. |
| 258 | +4. Optionally export fresh Postman results for the release notes. |
| 259 | + |
253 | 260 | ## Troubleshooting |
254 | | -- **`sqlite3.OperationalError: no such table`** – run `alembic upgrade head` to |
| 261 | +- **`sqlite3.OperationalError: no such table`** – run `alembic upgrade head` to |
255 | 262 | apply migrations before starting the app or executing CLI commands. |
256 | | -- **Provider timeouts** – double-check internet connectivity and increase |
| 263 | +- **Provider timeouts** – double-check internet connectivity and increase |
257 | 264 | `REQUEST_TIMEOUT_SECONDS` if your network is slow. Enable a fallback provider |
258 | 265 | to improve resilience when the primary is down. |
259 | | -- **Repeated 429 on `/rates/refresh`** – the throttle is still active. Either wait |
| 266 | +- **Repeated 429 on `/rates/refresh`** – the throttle is still active. Either wait |
260 | 267 | for the window to elapse or lower `REFRESH_THROTTLE_SECONDS` for development. |
261 | | -- **CORS preflight failures** – set `CORS_ALLOWED_ORIGINS` (and related headers) |
| 268 | +- **CORS preflight failures** – set `CORS_ALLOWED_ORIGINS` (and related headers) |
262 | 269 | to include your frontend dev origin before reloading the app. |
263 | 270 |
|
264 | 271 | ### Docker Compose |
|
0 commit comments