Skip to content

Commit 0ffc550

Browse files
vdavezclaude
andcommitted
test: re-record contract integration cassettes for cursor-only pagination
The list_contracts page=1 removal changed the recorded request URI, so 32 contract/edge-case cassettes no longer matched. Re-recorded against live API (v4.6.9). Two expensive filter queries (awarding_agency, multi-param search) 504 at the gateway on re-record, so those two cassettes retain their prior valid 200 response with only the stale `&page=1` stripped from the request URI. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 329a50f commit 0ffc550

32 files changed

Lines changed: 3085 additions & 2 deletions

File tree

tests/cassettes/TestContractsIntegration.test_combined_filters_work_together

Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,4 +73,80 @@ interactions:
7373
status:
7474
code: 200
7575
message: OK
76+
- request:
77+
body: ''
78+
headers:
79+
accept:
80+
- '*/*'
81+
accept-encoding:
82+
- gzip, deflate
83+
connection:
84+
- keep-alive
85+
host:
86+
- tango.makegov.com
87+
user-agent:
88+
- python-httpx/0.28.1
89+
method: GET
90+
uri: https://tango.makegov.com/api/contracts/?limit=5&shape=key%2Cpiid%2Caward_date%2Crecipient%28display_name%29%2Cdescription%2Ctotal_contract_value&award_type=A&awarding_agency=4700&fiscal_year=2024&search=software
91+
response:
92+
body:
93+
string: '{"count":0,"next":null,"previous":null,"cursor":null,"previous_cursor":null,"results":[]}'
94+
headers:
95+
CF-RAY:
96+
- a02d54629de5a225-MSP
97+
Connection:
98+
- keep-alive
99+
Content-Type:
100+
- application/json
101+
Date:
102+
- Thu, 28 May 2026 12:40:45 GMT
103+
Nel:
104+
- '{"report_to":"cf-nel","success_fraction":0.0,"max_age":604800}'
105+
Report-To:
106+
- '{"group":"cf-nel","max_age":604800,"endpoints":[{"url":"https://a.nel.cloudflare.com/report/v4?s=9ozbhoqlmHg%2FBGCO%2BU%2FuSyUMSurNyI%2BL5N416679KkuooxHkj96WLLVZa1DLlXXURTb3mKbmc40DMWitSElNhQU1IOZ5sPnw6GDNBtkupPAPdNuji3YsIaUaa2Lh7HfnD%2FkUZrYpAGy2LC36n%2Fzy"}]}'
107+
Server:
108+
- cloudflare
109+
Transfer-Encoding:
110+
- chunked
111+
allow:
112+
- GET, HEAD, OPTIONS
113+
cf-cache-status:
114+
- DYNAMIC
115+
content-length:
116+
- '89'
117+
cross-origin-opener-policy:
118+
- same-origin
119+
referrer-policy:
120+
- same-origin
121+
vary:
122+
- Accept, Cookie
123+
x-content-type-options:
124+
- nosniff
125+
x-execution-time:
126+
- 0.151s
127+
x-frame-options:
128+
- DENY
129+
x-ratelimit-burst-limit:
130+
- '1000'
131+
x-ratelimit-burst-remaining:
132+
- '985'
133+
x-ratelimit-burst-reset:
134+
- '14'
135+
x-ratelimit-daily-limit:
136+
- '2000000'
137+
x-ratelimit-daily-remaining:
138+
- '1999911'
139+
x-ratelimit-daily-reset:
140+
- '40754'
141+
x-ratelimit-limit:
142+
- '1000'
143+
x-ratelimit-remaining:
144+
- '985'
145+
x-ratelimit-reset:
146+
- '14'
147+
x-results-counttype:
148+
- exact
149+
status:
150+
code: 200
151+
message: OK
76152
version: 1

tests/cassettes/TestContractsIntegration.test_contract_cursor_pagination

Lines changed: 173 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,4 +171,177 @@ interactions:
171171
status:
172172
code: 200
173173
message: OK
174+
- request:
175+
body: ''
176+
headers:
177+
accept:
178+
- '*/*'
179+
accept-encoding:
180+
- gzip, deflate
181+
connection:
182+
- keep-alive
183+
host:
184+
- tango.makegov.com
185+
user-agent:
186+
- python-httpx/0.28.1
187+
method: GET
188+
uri: https://tango.makegov.com/api/contracts/?limit=5&shape=key%2Cpiid%2Caward_date%2Crecipient%28display_name%29%2Cdescription%2Ctotal_contract_value
189+
response:
190+
body:
191+
string: '{"count":84625240,"next":"https://tango.makegov.com/api/contracts/?limit=5&shape=key%2Cpiid%2Caward_date%2Crecipient%28display_name%29%2Cdescription%2Ctotal_contract_value&cursor=WyIyMDI2LTA1LTI2IiwgImZkNGYxMzA4LTY0NzUtNWViOS05ZTQzLTFmZDNiYTA5ZGYzNiJd","previous":null,"cursor":"WyIyMDI2LTA1LTI2IiwgImZkNGYxMzA4LTY0NzUtNWViOS05ZTQzLTFmZDNiYTA5ZGYzNiJd","previous_cursor":null,"results":[{"award_date":"2026-05-26","description":"CARDIOQUIP
192+
SERVICES","key":"CONT_AWD_36C26126P0571_3600_-NONE-_-NONE-","piid":"36C26126P0571","recipient":{"display_name":"CARDIOQUIP,
193+
LLC"},"total_contract_value":26901.64},{"award_date":"2026-05-26","description":"NON-PERSONAL
194+
SERVICES TO DEFINE A PRODUCT SPECIFICATION AND CREATE A CONCEPTUAL MODEL OF
195+
THE NATIONAL ROAD NETWORK (NRN).","key":"CONT_AWD_693JJ326P000012_6925_-NONE-_-NONE-","piid":"693JJ326P000012","recipient":{"display_name":"CULTIVATE
196+
GEOSPATIAL SOLUTIONS LLC"},"total_contract_value":369600.0},{"award_date":"2026-05-26","description":"URGENT
197+
REPLACE RECESSED LED PULSATING LIGHTING, U.S. SECRET SERVICES (USSS) HEADQUARTERS
198+
BUILDING, 950 H STREET, NW, WASHINGTON, DC 20223.","key":"CONT_AWD_47PE5226F0113_4740_47PF5126D0008_4740","piid":"47PE5226F0113","recipient":{"display_name":"MELWOOD
199+
HORTICULTURAL TRAINING CENTER, INC."},"total_contract_value":27500.0},{"award_date":"2026-05-26","description":"ESRI
200+
ARCGIS MAINTENANCE","key":"CONT_AWD_89503026FWA401176_8900_NNG15SD60B_8000","piid":"89503026FWA401176","recipient":{"display_name":"ADVANCED
201+
COMPUTER CONCEPTS, INC."},"total_contract_value":83384.92},{"award_date":"2026-05-26","description":"SURGICAL
202+
IMPLANT - HEART TAVR","key":"CONT_AWD_36C24126P0441_3600_-NONE-_-NONE-","piid":"36C24126P0441","recipient":{"display_name":"Edwards
203+
Lifesciences LLC"},"total_contract_value":68000.0}]}'
204+
headers:
205+
CF-RAY:
206+
- a02d54649a12511a-MSP
207+
Connection:
208+
- keep-alive
209+
Content-Type:
210+
- application/json
211+
Date:
212+
- Thu, 28 May 2026 12:40:45 GMT
213+
Nel:
214+
- '{"report_to":"cf-nel","success_fraction":0.0,"max_age":604800}'
215+
Report-To:
216+
- '{"group":"cf-nel","max_age":604800,"endpoints":[{"url":"https://a.nel.cloudflare.com/report/v4?s=841HljoWP2Hh5y3rYLmitigLJNzUZafDczTD57vtjDLOkzmWNPhRanGHUOcpVlzNj01EamXD0%2FQxvm3z39ZDuYeXW%2BgQBvJNPsk39hE2HqbcTZa6QS%2FhkZxIJJcsvePgeEBg7qCrVuBvW07G993H"}]}'
217+
Server:
218+
- cloudflare
219+
Transfer-Encoding:
220+
- chunked
221+
allow:
222+
- GET, HEAD, OPTIONS
223+
cf-cache-status:
224+
- DYNAMIC
225+
content-length:
226+
- '1793'
227+
cross-origin-opener-policy:
228+
- same-origin
229+
referrer-policy:
230+
- same-origin
231+
vary:
232+
- Accept, Cookie
233+
x-content-type-options:
234+
- nosniff
235+
x-execution-time:
236+
- 0.039s
237+
x-frame-options:
238+
- DENY
239+
x-ratelimit-burst-limit:
240+
- '1000'
241+
x-ratelimit-burst-remaining:
242+
- '984'
243+
x-ratelimit-burst-reset:
244+
- '14'
245+
x-ratelimit-daily-limit:
246+
- '2000000'
247+
x-ratelimit-daily-remaining:
248+
- '1999910'
249+
x-ratelimit-daily-reset:
250+
- '40754'
251+
x-ratelimit-limit:
252+
- '1000'
253+
x-ratelimit-remaining:
254+
- '984'
255+
x-ratelimit-reset:
256+
- '14'
257+
x-results-counttype:
258+
- approximate
259+
status:
260+
code: 200
261+
message: OK
262+
- request:
263+
body: ''
264+
headers:
265+
accept:
266+
- '*/*'
267+
accept-encoding:
268+
- gzip, deflate
269+
connection:
270+
- keep-alive
271+
host:
272+
- tango.makegov.com
273+
user-agent:
274+
- python-httpx/0.28.1
275+
method: GET
276+
uri: https://tango.makegov.com/api/contracts/?limit=5&cursor=WyIyMDI2LTA1LTI2IiwgImZkNGYxMzA4LTY0NzUtNWViOS05ZTQzLTFmZDNiYTA5ZGYzNiJd&shape=key%2Cpiid%2Caward_date%2Crecipient%28display_name%29%2Cdescription%2Ctotal_contract_value
277+
response:
278+
body:
279+
string: '{"count":84625240,"next":"https://tango.makegov.com/api/contracts/?limit=5&cursor=WyIyMDI2LTA1LTI2IiwgImY5ZDc4OTJmLTI1MGItNTcxYy04ZjI2LTlhMjYwMDBhYTk1NCJd&shape=key%2Cpiid%2Caward_date%2Crecipient%28display_name%29%2Cdescription%2Ctotal_contract_value","previous":"https://tango.makegov.com/api/contracts/?limit=5&cursor=eyJ2IjogWyIyMDI2LTA1LTI2IiwgImZkMzQ5OTVkLTM4ZmItNTNmYy1hYjYxLThjYjU5MGI5ZDkyNiJdLCAiZCI6ICJwcmV2In0%3D&shape=key%2Cpiid%2Caward_date%2Crecipient%28display_name%29%2Cdescription%2Ctotal_contract_value","cursor":"WyIyMDI2LTA1LTI2IiwgImY5ZDc4OTJmLTI1MGItNTcxYy04ZjI2LTlhMjYwMDBhYTk1NCJd","previous_cursor":"eyJ2IjogWyIyMDI2LTA1LTI2IiwgImZkMzQ5OTVkLTM4ZmItNTNmYy1hYjYxLThjYjU5MGI5ZDkyNiJdLCAiZCI6ICJwcmV2In0=","results":[{"award_date":"2026-05-26","description":"TENEBALE
280+
SOFTWARE","key":"CONT_AWD_89603026F0034_8960_NNG15SD76B_8000","piid":"89603026F0034","recipient":{"display_name":"ENTERPRISE
281+
TECHNOLOGY SOLUTIONS, INC."},"total_contract_value":96427.99},{"award_date":"2026-05-26","description":"TSFB
282+
SOFT PRESSURE WASH LOCATED IN RALEIGH, NC AT THE TERRY SANFORD FEDERAL BUILDING","key":"CONT_AWD_47PC5226F0297_4740_47PN0423A0004_4740","piid":"47PC5226F0297","recipient":{"display_name":"DAE
283+
SUNG LLC"},"total_contract_value":105000.9},{"award_date":"2026-05-26","description":"UIPATH","key":"CONT_AWD_1331L526FNB160100_1341_1331L521A13ES0015_1301","piid":"1331L526FNB160100","recipient":{"display_name":"GOVERNMENT
284+
ACQUISITIONS INC"},"total_contract_value":49851.72},{"award_date":"2026-05-26","description":"EMERGENCY
285+
SEWER REPAIR","key":"CONT_AWD_36C24626P0712_3600_-NONE-_-NONE-","piid":"36C24626P0712","recipient":{"display_name":"Kokowski
286+
Plumbing LLC"},"total_contract_value":35000.0},{"award_date":"2026-05-26","description":"HBG-21171-C--G-LIHT
287+
PROCUREMENT","key":"CONT_AWD_80NSSC26FA425_8000_NNG15SD42B_8000","piid":"80NSSC26FA425","recipient":{"display_name":"ARCHITECHTURE
288+
SOLUTIONS LLC"},"total_contract_value":45058.8}]}'
289+
headers:
290+
CF-RAY:
291+
- a02d54654afc511a-MSP
292+
Connection:
293+
- keep-alive
294+
Content-Type:
295+
- application/json
296+
Date:
297+
- Thu, 28 May 2026 12:40:45 GMT
298+
Nel:
299+
- '{"report_to":"cf-nel","success_fraction":0.0,"max_age":604800}'
300+
Report-To:
301+
- '{"group":"cf-nel","max_age":604800,"endpoints":[{"url":"https://a.nel.cloudflare.com/report/v4?s=1XK8b52tTUDHkwa2VTkS0JhL6YGA1puktffJaRcOkEvnSZs6dETPuUj4ld90oQG1fA%2FJBmLoMyB%2FiF4Ktjwm1wNiHuc0kjrz9oiRyhTn6a7jdV%2B04Nug5htp9VYn9norX7hklKdVLBjj1BDC5n0Y"}]}'
302+
Server:
303+
- cloudflare
304+
Transfer-Encoding:
305+
- chunked
306+
allow:
307+
- GET, HEAD, OPTIONS
308+
cf-cache-status:
309+
- DYNAMIC
310+
content-length:
311+
- '1957'
312+
cross-origin-opener-policy:
313+
- same-origin
314+
referrer-policy:
315+
- same-origin
316+
vary:
317+
- Accept, Cookie
318+
x-content-type-options:
319+
- nosniff
320+
x-execution-time:
321+
- 0.038s
322+
x-frame-options:
323+
- DENY
324+
x-ratelimit-burst-limit:
325+
- '1000'
326+
x-ratelimit-burst-remaining:
327+
- '983'
328+
x-ratelimit-burst-reset:
329+
- '14'
330+
x-ratelimit-daily-limit:
331+
- '2000000'
332+
x-ratelimit-daily-remaining:
333+
- '1999909'
334+
x-ratelimit-daily-reset:
335+
- '40754'
336+
x-ratelimit-limit:
337+
- '1000'
338+
x-ratelimit-remaining:
339+
- '983'
340+
x-ratelimit-reset:
341+
- '14'
342+
x-results-counttype:
343+
- approximate
344+
status:
345+
code: 200
346+
message: OK
174347
version: 1

tests/cassettes/TestContractsIntegration.test_contract_data_object_parsing

Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,4 +83,92 @@ interactions:
8383
status:
8484
code: 200
8585
message: OK
86+
- request:
87+
body: ''
88+
headers:
89+
accept:
90+
- '*/*'
91+
accept-encoding:
92+
- gzip, deflate
93+
connection:
94+
- keep-alive
95+
host:
96+
- tango.makegov.com
97+
user-agent:
98+
- python-httpx/0.28.1
99+
method: GET
100+
uri: https://tango.makegov.com/api/contracts/?limit=5&shape=key%2Cpiid%2Caward_date%2Crecipient%28display_name%29%2Cdescription%2Ctotal_contract_value
101+
response:
102+
body:
103+
string: '{"count":84625240,"next":"https://tango.makegov.com/api/contracts/?limit=5&shape=key%2Cpiid%2Caward_date%2Crecipient%28display_name%29%2Cdescription%2Ctotal_contract_value&cursor=WyIyMDI2LTA1LTI2IiwgImZkNGYxMzA4LTY0NzUtNWViOS05ZTQzLTFmZDNiYTA5ZGYzNiJd","previous":null,"cursor":"WyIyMDI2LTA1LTI2IiwgImZkNGYxMzA4LTY0NzUtNWViOS05ZTQzLTFmZDNiYTA5ZGYzNiJd","previous_cursor":null,"results":[{"award_date":"2026-05-26","description":"CARDIOQUIP
104+
SERVICES","key":"CONT_AWD_36C26126P0571_3600_-NONE-_-NONE-","piid":"36C26126P0571","recipient":{"display_name":"CARDIOQUIP,
105+
LLC"},"total_contract_value":26901.64},{"award_date":"2026-05-26","description":"NON-PERSONAL
106+
SERVICES TO DEFINE A PRODUCT SPECIFICATION AND CREATE A CONCEPTUAL MODEL OF
107+
THE NATIONAL ROAD NETWORK (NRN).","key":"CONT_AWD_693JJ326P000012_6925_-NONE-_-NONE-","piid":"693JJ326P000012","recipient":{"display_name":"CULTIVATE
108+
GEOSPATIAL SOLUTIONS LLC"},"total_contract_value":369600.0},{"award_date":"2026-05-26","description":"URGENT
109+
REPLACE RECESSED LED PULSATING LIGHTING, U.S. SECRET SERVICES (USSS) HEADQUARTERS
110+
BUILDING, 950 H STREET, NW, WASHINGTON, DC 20223.","key":"CONT_AWD_47PE5226F0113_4740_47PF5126D0008_4740","piid":"47PE5226F0113","recipient":{"display_name":"MELWOOD
111+
HORTICULTURAL TRAINING CENTER, INC."},"total_contract_value":27500.0},{"award_date":"2026-05-26","description":"ESRI
112+
ARCGIS MAINTENANCE","key":"CONT_AWD_89503026FWA401176_8900_NNG15SD60B_8000","piid":"89503026FWA401176","recipient":{"display_name":"ADVANCED
113+
COMPUTER CONCEPTS, INC."},"total_contract_value":83384.92},{"award_date":"2026-05-26","description":"SURGICAL
114+
IMPLANT - HEART TAVR","key":"CONT_AWD_36C24126P0441_3600_-NONE-_-NONE-","piid":"36C24126P0441","recipient":{"display_name":"Edwards
115+
Lifesciences LLC"},"total_contract_value":68000.0}]}'
116+
headers:
117+
CF-RAY:
118+
- a02d534f0bb35108-MSP
119+
Connection:
120+
- keep-alive
121+
Content-Type:
122+
- application/json
123+
Date:
124+
- Thu, 28 May 2026 12:40:01 GMT
125+
Nel:
126+
- '{"report_to":"cf-nel","success_fraction":0.0,"max_age":604800}'
127+
Report-To:
128+
- '{"group":"cf-nel","max_age":604800,"endpoints":[{"url":"https://a.nel.cloudflare.com/report/v4?s=61IKmTo6jCljNLkAHDJvbKOWuzjus7ZEJjg8pMhMCwrM8EBDsELraTacXWOlXZROvWyNv8bFqM29iQZT7ZeRADUITant%2B1BiS%2BxNOIVHtD4pKOxmGFMjF5wQfctcaSyg1oA9JmurJydHCVDU4ReF"}]}'
129+
Server:
130+
- cloudflare
131+
Transfer-Encoding:
132+
- chunked
133+
allow:
134+
- GET, HEAD, OPTIONS
135+
cf-cache-status:
136+
- DYNAMIC
137+
content-length:
138+
- '1793'
139+
cross-origin-opener-policy:
140+
- same-origin
141+
referrer-policy:
142+
- same-origin
143+
vary:
144+
- Accept, Cookie
145+
x-content-type-options:
146+
- nosniff
147+
x-execution-time:
148+
- 0.040s
149+
x-frame-options:
150+
- DENY
151+
x-ratelimit-burst-limit:
152+
- '1000'
153+
x-ratelimit-burst-remaining:
154+
- '988'
155+
x-ratelimit-burst-reset:
156+
- '36'
157+
x-ratelimit-daily-limit:
158+
- '2000000'
159+
x-ratelimit-daily-remaining:
160+
- '1999920'
161+
x-ratelimit-daily-reset:
162+
- '40798'
163+
x-ratelimit-limit:
164+
- '1000'
165+
x-ratelimit-remaining:
166+
- '988'
167+
x-ratelimit-reset:
168+
- '36'
169+
x-results-counttype:
170+
- approximate
171+
status:
172+
code: 200
173+
message: OK
86174
version: 1

0 commit comments

Comments
 (0)