Repository navigation
feat(aw-client-rust): add get_classes with fallback to the default classes - #735
Merged
ErikBjare merged 1 commit intoSep 27, 2026
Merged
Conversation
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #735 +/- ##
===========================================
+ Coverage 70.81% 81.46% +10.65%
===========================================
Files 51 80 +29
Lines 2916 9789 +6873
===========================================
+ Hits 2065 7975 +5910
- Misses 851 1814 +963 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
16 tasks done
0xbrayo
force-pushed
the
feat/aw-client-get-classes
branch
2 times, most recently
from
September 26, 2026 19:13
941220b to
a62711a
Compare
Member
Author
|
@greptile review |
0xbrayo
force-pushed
the
feat/aw-client-get-classes
branch
from
September 26, 2026 19:48
a62711a to
dec63ea
Compare
Member
Author
|
@greptile review |
…asses Mirrors aw_client.classes.get_classes(): read the "classes" setting and fall back to the default classes when the request fails or the setting is unset or invalid. The parsing and fallback rules are the existing classes_from_settings_json; this only adds the fetch.
0xbrayo
force-pushed
the
feat/aw-client-get-classes
branch
from
September 26, 2026 20:13
dec63ea to
76e85a3
Compare
Member
Author
|
@greptile review |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of #724 (aw-client-rust parity with the Python client).
Adds
AwClient::get_classes()(async and blocking), the counterpart ofaw_client.classes.get_classes()in Python:classessetting withget_setting("classes");classes::classes_from_settings_json, which already falls back todefault_classes()fornull, empty or invalid values and decodes double-encoded payloads;default_classes(), as Python does.It returns the classes directly rather than a
Result, because every failure falls back to the defaults. Unlike the Python helper, it uses the caller's client (host, port, API key) instead of building its own client against the default production server.Tests
A mock-server test covers: a server-provided class list is used; an unset (
null) setting → defaults; a 500 → defaults.