From 250eda9460217a94e428be4f059b540d38282813 Mon Sep 17 00:00:00 2001 From: Ed Harrod Date: Thu, 23 Oct 2025 11:28:56 +0100 Subject: [PATCH 1/3] agents: Add AGENTS.md file --- .DS_Store | Bin 6148 -> 8196 bytes AGENTS.md | 113 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ CLAUDE.md | 5 +++ 3 files changed, 118 insertions(+) create mode 100644 AGENTS.md create mode 100644 CLAUDE.md diff --git a/.DS_Store b/.DS_Store index 9146fe0cb3aab07f6ed8c1130d11342053e9ccd4..cf769f1c5afecc3f7e9a9f4db6ed385df3fd3f2a 100644 GIT binary patch literal 8196 zcmeHMy=xRf6n}FcdUyz;DX#M%r6hRRXyqlG7Gfdf4>0$U%bo1q29pcg$hLwJJ4t6{ zW1$EN7FIC|78Y7+Cn$;_3Qp0i4;g z_YFW!3N-b%63I8d)|n&{DbLp1OJv z##NXSLuhyCi_#pjY-FINb|<0TNf=~dDiop6;a61VB+6R4(PhA8Af5qPyJu;d7HAQF z+v@kzcWiCPuT*NDU&Ga0aO%L%8{YGo?G}w4ES6gQ3&8`pV+WW9cAHkLuLt7(7T0m? zm9LL32Oku6=-crlQT)?r_@^9f^#_g`APG(j(^*IIFrFv79YLo z$$4l~19MTexlCLG7pCPrUUnxp)}wha{+vUyg^hnp=Hnpnm*^_3fWb1xi&Up7dW#lp zKB<$#tvSC>?>F;nn%|K7bH1Z_*!<@u|18xok8Sd(Ve@_W+SYP@cS{?E$s;fHIu89g zpJWRQU!OV|%w1b%&PKl^(L)`_{y1~A{|qsGw2qVX7A~d>Esgo=(ke$4)pNfh4afXm z3*$9@Jl43Dhn(upwN=}Pt-?5|{aDrc&Z=aftB?iQ) z4zuH=%?n8$RC`F1k7cbFc?-Y0ocaJ0JAlnD0vKS)!6f61 z)m_`tFcQ>^6d!H4-vu0zC5O_)o1HB^|QPS|0v3F{H?f2t-oxzLs=`2UA6;0 z{0adxEf4AZn|uB3$+Cz@CtKLGjssxtwX~*OkoEtW!QcP)USN)~%Ye(k$Qcls%3Ng@ z=BBoeIm%kQh(3=lo3snGR4y1)IS#4Hamer=hWK5Csq`ru8EA5 delta 136 zcmZp1XfcprU|?W$DortDU=RQ@Ie-{MGqg`E6q~50D9Q|EGlInm7;+d=8H!VilXE5( zsxvZAwh>X7EG{ZOnOl@+@_sS#jirk0i`h9i1VLJWK!6)axB_we#=`H+llf%~85t(q T@JRD8L97AU%&=2.18.4`, `six>=1.11.0` +- **Test**: `pytest`, `pytest-cov`, `requests_mock` + +## Testing Approach + +Tests use `requests_mock` to mock HTTP responses. The pattern: + +1. Create a `Client` instance +2. Mount mock adapter to session: `adapter.register_uri(method, url, ...)` +3. Call client method and assert response + +Recent additions test the `get_balances()` method with `account_id` parameter for filtering results by account. + +## Git Workflow + +When making changes: + +1. Run `git pull` before creating a new branch +2. Branch naming: `{username}-{issue-number}-{description}` +3. Commit messages: Present tense, describe *why* not *what* +4. Example: `"client: Add account_id parameter to get_balances method"` +5. Push and create PR when ready + +## Notes on Code Generation + +The `client.py` file contains ~100+ methods that are auto-generated from Luno's API specification. When modifying or adding methods: + +- Follow existing docstring format (includes HTTP method, path, permissions, parameter descriptions) +- Each method constructs a `req` dict with parameters and calls `self.do()` +- Type hints in docstrings use `:type param: type_name` format for Python 2 compatibility + +## File Editing Requirements + +Always ensure files end with a newline character. This maintains consistency with Git diffs and repository standards. diff --git a/CLAUDE.md b/CLAUDE.md new file mode 100644 index 0000000..ccc05ab --- /dev/null +++ b/CLAUDE.md @@ -0,0 +1,5 @@ +# CLAUDE.md + +This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository. + +For compatibility with multiple agents, the instructions are located at @AGENTS.md (see [AGENTS.md](./AGENTS.md). From 8a324fd78e09fb116d064d49662da47eaf90f367 Mon Sep 17 00:00:00 2001 From: Ed Harrod Date: Thu, 23 Oct 2025 11:56:04 +0100 Subject: [PATCH 2/3] Apply suggestion from @echarrod --- AGENTS.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/AGENTS.md b/AGENTS.md index 4095d2c..e6bfdd5 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -1,6 +1,6 @@ # AGENTS.md -This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository. +This file provides guidance to agents (e.g. Claude Code / GitHub CoPilot) when working with code in this repository. ## Project Overview From 1509e244c53c129da9957a4e3ca67a20b27575c4 Mon Sep 17 00:00:00 2001 From: Ed Harrod Date: Thu, 23 Oct 2025 11:58:35 +0100 Subject: [PATCH 3/3] gitignore: Remove .DS_STORE --- .DS_Store | Bin 8196 -> 0 bytes 1 file changed, 0 insertions(+), 0 deletions(-) delete mode 100644 .DS_Store diff --git a/.DS_Store b/.DS_Store deleted file mode 100644 index cf769f1c5afecc3f7e9a9f4db6ed385df3fd3f2a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 8196 zcmeHMy=xRf6n}FcdUyz;DX#M%r6hRRXyqlG7Gfdf4>0$U%bo1q29pcg$hLwJJ4t6{ zW1$EN7FIC|78Y7+Cn$;_3Qp0i4;g z_YFW!3N-b%63I8d)|n&{DbLp1OJv z##NXSLuhyCi_#pjY-FINb|<0TNf=~dDiop6;a61VB+6R4(PhA8Af5qPyJu;d7HAQF z+v@kzcWiCPuT*NDU&Ga0aO%L%8{YGo?G}w4ES6gQ3&8`pV+WW9cAHkLuLt7(7T0m? zm9LL32Oku6=-crlQT)?r_@^9f^#_g`APG(j(^*IIFrFv79YLo z$$4l~19MTexlCLG7pCPrUUnxp)}wha{+vUyg^hnp=Hnpnm*^_3fWb1xi&Up7dW#lp zKB<$#tvSC>?>F;nn%|K7bH1Z_*!<@u|18xok8Sd(Ve@_W+SYP@cS{?E$s;fHIu89g zpJWRQU!OV|%w1b%&PKl^(L)`_{y1~A{|qsGw2qVX7A~d>Esgo=(ke$4)pNfh4afXm z3*$9@Jl43Dhn(upwN=}Pt-?5|{aDrc&Z=aftB?iQ) z4zuH=%?n8$RC`F1k7cbFc?-Y0ocaJ0JAlnD0vKS)!6f61 z)m_`tFcQ>^6d!H4-vu0zC5O_)o1HB^|QPS|0v3F{H?f2t-oxzLs=`2UA6;0 z{0adxEf4AZn|uB3$+Cz@CtKLGjssxtwX~*OkoEtW!QcP)USN)~%Ye(k$Qcls%3Ng@ z=BBoeIm%kQh(3=lo3snGR4y1)IS#4Hamer=hWK5Csq`ru8EA5