-
Notifications
You must be signed in to change notification settings - Fork 650
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
fix:change keysCommand default format auto #597
Conversation
cmd/bbolt/main_test.go
Outdated
key := fmt.Sprintf("%s-%d", name, i) | ||
if err := b.Put([]byte(key), []byte{0}); err != nil { | ||
for _, k := range []int64{10001, 10002} { | ||
if err := b.Put(convertInt64IntoBytes(t, k), []byte{0}); err != nil { |
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.
0d8163d
to
d641cad
Compare
@ahrtr I updated this accordingly, ptal 👍🏽 |
d641cad
to
337eafd
Compare
/assign @ahrtr |
@fuweid would appreciate your review :) |
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
cmd/bbolt/main_test.go
Outdated
@@ -677,3 +709,11 @@ func convertInt64IntoBytes(num int64) []byte { | |||
n := binary.PutVarint(buf, num) | |||
return buf[:n] | |||
} | |||
|
|||
func convertInt64IntoBytesString(nums ...int64) string { |
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.
func convertInt64IntoBytesString(nums ...int64) string { | |
func convertInt64KeysIntoHexString(nums ...int64) string { |
cmd/bbolt/main_test.go
Outdated
t.Logf("creating test bucket %s", tc.testBucket) | ||
b, bErr := tx.CreateBucketIfNotExists([]byte(tc.testBucket)) | ||
if bErr != nil { | ||
return fmt.Errorf("error creating test bucket '%s': '%v'", tc.testBucket, bErr) |
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.
return fmt.Errorf("error creating test bucket '%s': '%v'", tc.testBucket, bErr) | |
return fmt.Errorf("error creating test bucket %q: %v", tc.testBucket, bErr) |
Please also rebase this PR. |
Signed-off-by: Mustafa Elbehery <melbeher@redhat.com>
337eafd
to
09dd42f
Compare
@ahrtr done 👍🏽 |
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
Please update the readme in a followup PR. |
This PR changes keysCommand default format from ascii-encoded to auto
resolves ##588
cc @ahrtr