This repository was archived by the owner on Nov 8, 2024. It is now read-only.
feat: allow setting bandits initial configuration#72
Open
Conversation
f6651b6 to
5059d8c
Compare
d69872e to
cf37b6a
Compare
aarsilv
reviewed
Sep 27, 2024
Contributor
aarsilv
left a comment
There was a problem hiding this comment.
Looking good but let's cover these changes with automated tests!
|
|
||
| def test_init_valid(): | ||
| Configuration(flags_configuration='{"flags": {}}') | ||
| Configuration(flags_configuration=b'{"flags": {}}') |
Contributor
There was a problem hiding this comment.
Since we're allowing bytes or a string, I imagine we should test both.
Also, let's have another test for initialization with a provided bandit configuration so we know it works!
Collaborator
Author
There was a problem hiding this comment.
String is essentially deprecated and removed in 4.0.0
| def __init__( | ||
| self, | ||
| flags_configuration: Union[bytes, str], | ||
| bandits_configuration: Union[bytes, str, None] = None, |
aarsilv
approved these changes
Oct 8, 2024
schmit
approved these changes
Oct 9, 2024
|
Thanks, great stuff! Let's bump versions and publish after this change is in. |
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
labels: mergeable
Fixes: #issue
Motivation and Context
Description
Allow passing initial configuration for bandits.
How has this been tested?