j-andrews7 / kenpompy

A simple yet comprehensive web scraper for kenpom.com.
https://kenpompy.readthedocs.io/en/latest/?badge=latest
GNU General Public License v3.0
70 stars 21 forks source link

CI/CD: Rate limiting between cases #85

Closed esqew closed 9 months ago

esqew commented 9 months ago

Our test suite has been getting tripped up by a seemingly more aggressive Cloudflare rate limit, especially when calling misc.py::get_current_season() (here's a recent example).

While I'm doing a bit of finalization on the analysis to confirm this fact, I would propose we let the test suite "breathe" for a few seconds between cases to avoid consistently tripping this rate limit.

This will definitely increase the total time required to run the whole suite but I believe the trade-off is more than acceptable.

j-andrews7 commented 9 months ago

Yeah, I've noticed this a time or two, probably a smart idea. The tests are already pretty quick, even doubling the time they take won't really matter, the env build takes way longer.