Skip to content
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

chore(store/v2): Increase storev2 tests coverage #21094

Merged
merged 39 commits into from
Aug 9, 2024

Conversation

sontrinh16
Copy link
Member

@sontrinh16 sontrinh16 commented Jul 26, 2024

Description

ref: #21040

  • migration 73.0%
    Screenshot 2024-08-07 at 19 28 29

  • pruning 82.4%
    Screenshot 2024-08-07 at 19 28 41

  • snapshot 51.1%
    Screenshot 2024-08-07 at 19 30 42

  • commitment with iavl backend 71.2% ( result from go tool cover -html=coverage.out )
    Screenshot 2024-08-07 at 19 36 41

  • storage 70.2% ( result from go tool cover -html=coverage.out )
    Screenshot 2024-08-07 at 19 39 53


Author Checklist

All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.

I have...

  • included the correct type prefix in the PR title, you can find examples of the prefixes below:
  • confirmed ! in the type prefix if API or client breaking change
  • targeted the correct branch (see PR Targeting)
  • provided a link to the relevant issue or specification
  • reviewed "Files changed" and left comments if necessary
  • included the necessary unit and integration tests
  • added a changelog entry to CHANGELOG.md
  • updated the relevant documentation or specification, including comments for documenting Go code
  • confirmed all CI checks have passed

Reviewers Checklist

All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.

Please see Pull Request Reviewer section in the contributing guide for more information on how to review a pull request.

I have...

  • confirmed the correct type prefix in the PR title
  • confirmed all author checklist items have been addressed
  • reviewed state machine logic, API design and naming, documentation is accurate, tests and test coverage

Summary by CodeRabbit

Summary by CodeRabbit

  • New Features

    • Introduced new test functions to validate the functionality of the commitment store, migration manager, pruning manager, and database restore operations.
    • Added a method to retrieve the latest snapshot from the store.
  • Bug Fixes

    • Increased timeout parameters in tests to reduce false negatives related to timing issues.
  • Tests

    • Expanded test suite for commitment, migration, pruning, and snapshot functionalities, including tests for concurrent behaviors and data integrity during restore operations.

Copy link
Contributor

coderabbitai bot commented Jul 26, 2024

Walkthrough

Walkthrough

The changes enhance the testing framework across various packages by introducing multiple new test functions that validate essential functionalities, such as proof retrieval, migration behavior, pruning operations, and snapshot management. Additionally, existing tests have been modified to improve timing reliability, promoting better robustness and concurrency handling within the system.

Changes

Files Change Summary
store/v2/commitment/store_test_suite.go, store/v2/migration/manager_test.go, store/v2/pruning/manager_test.go, store/v2/snapshots/manager_test.go New test functions added to validate core functionalities in commitment, migration, pruning, and snapshots.
store/v2/root/store_test.go Timeout parameters in an existing test function modified for robustness.
store/v2/storage/storage_test_suite.go New test function added to validate database restore functionality.

Sequence Diagram(s)

sequenceDiagram
    participant Client
    participant CommitStore
    participant MigrationManager
    participant PruningManager
    participant Database
    participant SnapshotManager

    Client->>CommitStore: Commit Changes
    CommitStore->>CommitStore: Retrieve Proofs
    CommitStore->>PruningManager: Signal Prune
    PruningManager->>CommitStore: Validate Data Access
    Client->>MigrationManager: Start Migration
    MigrationManager->>CommitStore: Apply Changesets
    MigrationManager->>Database: Restore State
    Database->>Client: Return Restored Data
    Client->>SnapshotManager: Take Snapshot
    SnapshotManager->>CommitStore: Create Snapshot
    PruningManager->>SnapshotManager: Validate Pruning
Loading

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share
Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

store/v2/storage/storage_test_suite.go Dismissed Show dismissed Hide dismissed
@sontrinh16 sontrinh16 marked this pull request as ready for review July 30, 2024 14:24
@sontrinh16 sontrinh16 requested a review from a team as a code owner July 30, 2024 14:24
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

Review details

Configuration used: .coderabbit.yml
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 8e0bf86 and 25f1365.

Files selected for processing (8)
  • store/v2/commitment/store_test_suite.go (1 hunks)
  • store/v2/migration/manager_test.go (2 hunks)
  • store/v2/pruning/manager_test.go (1 hunks)
  • store/v2/root/store_test.go (1 hunks)
  • store/v2/snapshots/manager.go (2 hunks)
  • store/v2/snapshots/manager_test.go (2 hunks)
  • store/v2/storage/storage_test_suite.go (1 hunks)
  • tests/e2e/accounts/lockup/periodic_lockup_test_suite.go (2 hunks)
Files skipped from review due to trivial changes (1)
  • tests/e2e/accounts/lockup/periodic_lockup_test_suite.go
Additional context used
Path-based instructions (7)
store/v2/commitment/store_test_suite.go (1)

Pattern **/*.go: Review the Golang code for conformity with the Uber Golang style guide, highlighting any deviations.

store/v2/migration/manager_test.go (2)

Pattern **/*.go: Review the Golang code for conformity with the Uber Golang style guide, highlighting any deviations.


Pattern **/*_test.go: "Assess the unit test code assessing sufficient code coverage for the changes associated in the pull request"

store/v2/pruning/manager_test.go (2)

Pattern **/*.go: Review the Golang code for conformity with the Uber Golang style guide, highlighting any deviations.


Pattern **/*_test.go: "Assess the unit test code assessing sufficient code coverage for the changes associated in the pull request"

store/v2/snapshots/manager_test.go (2)

Pattern **/*.go: Review the Golang code for conformity with the Uber Golang style guide, highlighting any deviations.


Pattern **/*_test.go: "Assess the unit test code assessing sufficient code coverage for the changes associated in the pull request"

store/v2/snapshots/manager.go (1)

Pattern **/*.go: Review the Golang code for conformity with the Uber Golang style guide, highlighting any deviations.

store/v2/storage/storage_test_suite.go (1)

Pattern **/*.go: Review the Golang code for conformity with the Uber Golang style guide, highlighting any deviations.

store/v2/root/store_test.go (2)

Pattern **/*.go: Review the Golang code for conformity with the Uber Golang style guide, highlighting any deviations.


Pattern **/*_test.go: "Assess the unit test code assessing sufficient code coverage for the changes associated in the pull request"

Additional comments not posted (7)
store/v2/commitment/store_test_suite.go (2)

168-209: Ensure comprehensive coverage of edge cases.

The function TestStore_GetProof tests the proof retrieval functionality. It is important to ensure that all edge cases, such as empty keys or non-existent versions, are covered.


211-243: Ensure comprehensive coverage of edge cases.

The function TestStore_Get tests the value retrieval functionality. It is important to ensure that all edge cases, such as empty keys or non-existent versions, are covered.

store/v2/migration/manager_test.go (1)

122-220: Ensure comprehensive coverage of edge cases.

The function TestStartMigrateState tests the migration process. It is important to ensure that all edge cases, such as empty changesets or interrupted migrations, are covered.

store/v2/pruning/manager_test.go (1)

156-258: Ensure comprehensive coverage of edge cases.

The function TestSignalCommit tests the interaction between commit signaling and pruning. It is important to ensure that all edge cases, such as interrupted commits or concurrent pruning operations, are covered.

store/v2/snapshots/manager.go (2)

118-123: LGTM! Ensure proper concurrency handling.

The method correctly locks the mutex to ensure thread safety when accessing the current operation.


174-176: LGTM! Ensure proper error handling.

The method correctly retrieves the latest snapshot from the store and handles potential errors.

store/v2/root/store_test.go (1)

633-633: Increase timeout duration and polling interval.

The timeout duration has been increased from 5 seconds to 10 seconds, and the polling interval has been changed from 100 milliseconds to 1 second. This adjustment should enhance the robustness of the test by reducing the likelihood of false negatives due to timing issues.

Comment on lines 502 to 532
func TestSnapshot_SnapshotIfApplicable(t *testing.T) {
store := setupStore(t)

items := [][]byte{
{1, 2, 3},
{4, 5, 6},
{7, 8, 9},
}
commitSnapshotter := &mockCommitSnapshotter{
items: items,
}
extSnapshotter := newExtSnapshotter(10)

snapshotOpts := snapshots.NewSnapshotOptions(1, 1)

manager := snapshots.NewManager(store, snapshotOpts, commitSnapshotter, &mockStorageSnapshotter{}, nil, coretesting.NewNopLogger())
err := manager.RegisterExtensions(extSnapshotter)
require.NoError(t, err)

manager.SnapshotIfApplicable(4)

checkLatestHeight := func() bool {
latestSnapshot, _ := manager.GetLatestSnapshot()
return latestSnapshot.Height == 4
}

require.Eventually(t, checkLatestHeight, time.Second*10, time.Second)

pruned, err := manager.Prune(1)
require.NoError(t, err)
require.Equal(t, uint64(0), pruned)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ensure proper error handling for GetLatestSnapshot.

The function does not handle potential errors from GetLatestSnapshot. Ensure error handling to avoid unexpected behavior.

-	checkLatestHeight := func() bool {
-		latestSnapshot, _ := manager.GetLatestSnapshot()
-		return latestSnapshot.Height == 4
-	}
+	checkLatestHeight := func() bool {
+		latestSnapshot, err := manager.GetLatestSnapshot()
+		if err != nil {
+			return false
+		}
+		return latestSnapshot.Height == 4
+	}
Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
func TestSnapshot_SnapshotIfApplicable(t *testing.T) {
store := setupStore(t)
items := [][]byte{
{1, 2, 3},
{4, 5, 6},
{7, 8, 9},
}
commitSnapshotter := &mockCommitSnapshotter{
items: items,
}
extSnapshotter := newExtSnapshotter(10)
snapshotOpts := snapshots.NewSnapshotOptions(1, 1)
manager := snapshots.NewManager(store, snapshotOpts, commitSnapshotter, &mockStorageSnapshotter{}, nil, coretesting.NewNopLogger())
err := manager.RegisterExtensions(extSnapshotter)
require.NoError(t, err)
manager.SnapshotIfApplicable(4)
checkLatestHeight := func() bool {
latestSnapshot, _ := manager.GetLatestSnapshot()
return latestSnapshot.Height == 4
}
require.Eventually(t, checkLatestHeight, time.Second*10, time.Second)
pruned, err := manager.Prune(1)
require.NoError(t, err)
require.Equal(t, uint64(0), pruned)
func TestSnapshot_SnapshotIfApplicable(t *testing.T) {
store := setupStore(t)
items := [][]byte{
{1, 2, 3},
{4, 5, 6},
{7, 8, 9},
}
commitSnapshotter := &mockCommitSnapshotter{
items: items,
}
extSnapshotter := newExtSnapshotter(10)
snapshotOpts := snapshots.NewSnapshotOptions(1, 1)
manager := snapshots.NewManager(store, snapshotOpts, commitSnapshotter, &mockStorageSnapshotter{}, nil, coretesting.NewNopLogger())
err := manager.RegisterExtensions(extSnapshotter)
require.NoError(t, err)
manager.SnapshotIfApplicable(4)
checkLatestHeight := func() bool {
latestSnapshot, err := manager.GetLatestSnapshot()
if err != nil {
return false
}
return latestSnapshot.Height == 4
}
require.Eventually(t, checkLatestHeight, time.Second*10, time.Second)
pruned, err := manager.Prune(1)
require.NoError(t, err)
require.Equal(t, uint64(0), pruned)

store/v2/snapshots/manager_test.go Outdated Show resolved Hide resolved
Comment on lines +643 to +707
func (s *StorageTestSuite) TestDatabase_Restore() {
db, err := s.NewDB(s.T().TempDir())
s.Require().NoError(err)
defer db.Close()

toVersion := uint64(10)
keyCount := 10

// for versions 1-10, set 10 keys
for v := uint64(1); v <= toVersion; v++ {
cs := corestore.NewChangesetWithPairs(map[string]corestore.KVPairs{storeKey1: {}})
for i := 0; i < keyCount; i++ {
key := fmt.Sprintf("key%03d", i)
val := fmt.Sprintf("val%03d-%03d", i, v)

cs.AddKVPair(storeKey1Bytes, corestore.KVPair{Key: []byte(key), Value: []byte(val)})
}

s.Require().NoError(db.ApplyChangeset(v, cs))
}

latestVersion, err := db.GetLatestVersion()
s.Require().NoError(err)
s.Require().Equal(uint64(10), latestVersion)

chStorage := make(chan *corestore.StateChanges, 5)

go func() {
for i := uint64(11); i <= 15; i++ {
kvPairs := []corestore.KVPair{}
for j := 0; j < keyCount; j++ {
key := fmt.Sprintf("key%03d-%03d", j, i)
val := fmt.Sprintf("val%03d-%03d", j, i)

kvPairs = append(kvPairs, corestore.KVPair{Key: []byte(key), Value: []byte(val)})
}
chStorage <- &corestore.StateChanges{
Actor: storeKey1Bytes,
StateChanges: kvPairs,
}
}
close(chStorage)
}()

// restore with snapshot version smaller than latest version
// should return an error
err = db.Restore(9, chStorage)
s.Require().Error(err)

// restore
err = db.Restore(11, chStorage)
s.Require().NoError(err)

// check the storage
for i := uint64(11); i <= 15; i++ {
for j := 0; j < keyCount; j++ {
key := fmt.Sprintf("key%03d-%03d", j, i)
val := fmt.Sprintf("val%03d-%03d", j, i)

v, err := db.Get(storeKey1Bytes, 11, []byte(key))
s.Require().NoError(err)
s.Require().Equal([]byte(val), v)
}
}
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ensure proper synchronization when accessing shared resources.

The function uses a goroutine to simulate state changes. Ensure proper synchronization to avoid potential data races.

-	go func() {
-		for i := uint64(11); i <= 15; i++ {
-			kvPairs := []corestore.KVPair{}
-			for j := 0; j < keyCount; j++ {
-				key := fmt.Sprintf("key%03d-%03d", j, i)
-				val := fmt.Sprintf("val%03d-%03d", j, i)
-				kvPairs = append(kvPairs, corestore.KVPair{Key: []byte(key), Value: []byte(val)})
-			}
-			chStorage <- &corestore.StateChanges{
-				Actor:        storeKey1Bytes,
-				StateChanges: kvPairs,
-			}
-		}
-		close(chStorage)
-	}()
+	go func() {
+		defer close(chStorage)
+		for i := uint64(11); i <= 15; i++ {
+			kvPairs := []corestore.KVPair{}
+			for j := 0; j < keyCount; j++ {
+				key := fmt.Sprintf("key%03d-%03d", j, i)
+				val := fmt.Sprintf("val%03d-%03d", j, i)
+				kvPairs = append(kvPairs, corestore.KVPair{Key: []byte(key), Value: []byte(val)})
+			}
+			chStorage <- &corestore.StateChanges{
+				Actor:        storeKey1Bytes,
+				StateChanges: kvPairs,
+			}
+			time.Sleep(10 * time.Millisecond) // avoid potential data races
+		}
+	}()

Committable suggestion was skipped due to low confidence.

@cool-develope
Copy link
Contributor

overall lgtm, I've merged the upgrade PR, maybe need to sync

@sontrinh16
Copy link
Member Author

overall lgtm, I've merged the upgrade PR, maybe need to sync

gotcha

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

Review details

Configuration used: .coderabbit.yml
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 59bb870 and 86e1f95.

Files selected for processing (5)
  • store/v2/commitment/store_test_suite.go (1 hunks)
  • store/v2/migration/manager_test.go (2 hunks)
  • store/v2/pruning/manager_test.go (1 hunks)
  • store/v2/root/store_test.go (1 hunks)
  • store/v2/storage/storage_test_suite.go (1 hunks)
Files skipped from review as they are similar to previous changes (5)
  • store/v2/commitment/store_test_suite.go
  • store/v2/migration/manager_test.go
  • store/v2/pruning/manager_test.go
  • store/v2/root/store_test.go
  • store/v2/storage/storage_test_suite.go

@cool-develope
Copy link
Contributor

could you please revert new APIs?

@sontrinh16
Copy link
Member Author

could you please revert new APIs?

removed

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

Review details

Configuration used: .coderabbit.yml
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 86e1f95 and 496c501.

Files selected for processing (2)
  • store/v2/snapshots/manager.go (1 hunks)
  • store/v2/snapshots/manager_test.go (5 hunks)
Additional context used
Path-based instructions (2)
store/v2/snapshots/manager_test.go (2)

Pattern **/*.go: Review the Golang code for conformity with the Uber Golang style guide, highlighting any deviations.


Pattern **/*_test.go: "Assess the unit test code assessing sufficient code coverage for the changes associated in the pull request"

store/v2/snapshots/manager.go (1)

Pattern **/*.go: Review the Golang code for conformity with the Uber Golang style guide, highlighting any deviations.

Additional comments not posted (2)
store/v2/snapshots/manager_test.go (1)

527-530: Ensure proper error handling for GetLatestSnapshot.

The function does not handle potential errors from GetLatestSnapshot. Ensure error handling to avoid unexpected behavior.

-	checkLatestHeight := func() bool {
-		latestSnapshot, _ := manager.GetLatestSnapshot()
-		return latestSnapshot.Height == 4
-	}
+	checkLatestHeight := func() bool {
+		latestSnapshot, err := manager.GetLatestSnapshot()
+		if err != nil {
+			return false
+		}
+		return latestSnapshot.Height == 4
+	}
store/v2/snapshots/manager.go (1)

167-169: LGTM!

The method encapsulates the call to m.store.GetLatest(), streamlining access to the latest snapshot data. The code changes are approved.

Comment on lines +483 to +490
go func() {
checkError := func() bool {
_, err = manager.Prune(1)
return err != nil
}

require.Eventually(t, checkError, time.Millisecond*200, time.Millisecond)
}()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ensure proper error handling for manager.Prune in the goroutine.

The function does not handle potential errors from manager.Prune. Ensure error handling to avoid unexpected behavior.

-	go func() {
-		checkError := func() bool {
-			_, err = manager.Prune(1)
-			return err != nil
-		}
-		require.Eventually(t, checkError, time.Millisecond*200, time.Millisecond)
-	}()
+	go func() {
+		checkError := func() bool {
+			_, err := manager.Prune(1)
+			if err != nil {
+				return true
+			}
+			return false
+		}
+		require.Eventually(t, checkError, time.Millisecond*200, time.Millisecond)
+	}()
Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
go func() {
checkError := func() bool {
_, err = manager.Prune(1)
return err != nil
}
require.Eventually(t, checkError, time.Millisecond*200, time.Millisecond)
}()
go func() {
checkError := func() bool {
_, err := manager.Prune(1)
if err != nil {
return true
}
return false
}
require.Eventually(t, checkError, time.Millisecond*200, time.Millisecond)
}()

Comment on lines +455 to +462
go func() {
checkError := func() bool {
_, err := manager.Create(4)
return err != nil
}

require.Eventually(t, checkError, time.Millisecond*200, time.Millisecond)
}()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ensure proper error handling for manager.Create in the goroutine.

The function does not handle potential errors from manager.Create. Ensure error handling to avoid unexpected behavior.

-	go func() {
-		checkError := func() bool {
-			_, err := manager.Create(4)
-			return err != nil
-		}
-		require.Eventually(t, checkError, time.Millisecond*200, time.Millisecond)
-	}()
+	go func() {
+		checkError := func() bool {
+			_, err := manager.Create(4)
+			if err != nil {
+				return true
+			}
+			return false
+		}
+		require.Eventually(t, checkError, time.Millisecond*200, time.Millisecond)
+	}()
Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
go func() {
checkError := func() bool {
_, err := manager.Create(4)
return err != nil
}
require.Eventually(t, checkError, time.Millisecond*200, time.Millisecond)
}()
go func() {
checkError := func() bool {
_, err := manager.Create(4)
if err != nil {
return true
}
return false
}
require.Eventually(t, checkError, time.Millisecond*200, time.Millisecond)
}()

@sontrinh16
Copy link
Member Author

@cool-develope i added the percentage in the PR description

Copy link
Member

@tac0turtle tac0turtle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

Review details

Configuration used: .coderabbit.yml
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 496c501 and 67032e4.

Files selected for processing (1)
  • store/v2/snapshots/manager_test.go (5 hunks)
Additional context used
Path-based instructions (1)
store/v2/snapshots/manager_test.go (2)

Pattern **/*.go: Review the Golang code for conformity with the Uber Golang style guide, highlighting any deviations.


Pattern **/*_test.go: "Assess the unit test code assessing sufficient code coverage for the changes associated in the pull request"

Additional comments not posted (3)
store/v2/snapshots/manager_test.go (3)

455-462: Ensure proper error handling for manager.Create in the goroutine.

The function does not handle potential errors from manager.Create. Ensure error handling to avoid unexpected behavior.


483-490: Ensure proper error handling for manager.Prune in the goroutine.

The function does not handle potential errors from manager.Prune. Ensure error handling to avoid unexpected behavior.


528-529: Ensure proper error handling for GetLatest.

The function does not handle potential errors from GetLatest. Ensure error handling to avoid unexpected behavior.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

Review details

Configuration used: .coderabbit.yml
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 67032e4 and 74ded9f.

Files selected for processing (1)
  • store/v2/root/store_test.go (1 hunks)
Files skipped from review as they are similar to previous changes (1)
  • store/v2/root/store_test.go

@sontrinh16 sontrinh16 enabled auto-merge August 9, 2024 15:56
@sontrinh16 sontrinh16 added this pull request to the merge queue Aug 9, 2024
Merged via the queue into main with commit 7a59ce9 Aug 9, 2024
74 checks passed
@sontrinh16 sontrinh16 deleted the son/increase_storev2_tests branch August 9, 2024 16:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants