-
Notifications
You must be signed in to change notification settings - Fork 5.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixes cache issue from 703 and 679 #707
Conversation
@sonichi While I was in there, fixing cache, I noticed that the filter logic only ever applied to cached responses. Is this what was intended? Or is that a separate bug? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks Adam!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are right. There are some bugs about the filter check.
Co-authored-by: Chi Wang <[email protected]>
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #707 +/- ##
===========================================
+ Coverage 29.81% 49.08% +19.27%
===========================================
Files 27 27
Lines 3448 3455 +7
Branches 780 824 +44
===========================================
+ Hits 1028 1696 +668
+ Misses 2346 1582 -764
- Partials 74 177 +103
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
* Avoid creating cache database when cache_seed is None (which disables cache) * Add some debugging. * Removed some debugging. * Update autogen/oai/client.py Co-authored-by: Chi Wang <[email protected]> * Fixed missing filter function logic from oai/client.py --------- Co-authored-by: Chi Wang <[email protected]>
Why are these changes needed?
The cache database is created even when caching is disabled. This raises issues on read-only filesystems, and is also generally unpleasant, as it leaves debris everywhere it is run. This PR fixed the issue.
Related issue number
Closes #703 and #679
Checks