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

Update to Cadence v1.0.0-preview.39 #367

Closed
wants to merge 8 commits into from

Conversation

turbolent
Copy link
Member

@turbolent turbolent commented Jul 18, 2024

Description

Automatically update to:

Summary by CodeRabbit

  • Dependency Updates

    • Updated multiple dependencies to their latest versions for improved performance and security.
  • Improvements

    • Improved logging mechanism for clearer log management.
    • Simplified handling of transaction hashes and payload fields for better clarity and efficiency.
    • Streamlined logic for processing transaction event attributes, enhancing maintainability.
    • Enhanced type safety in transaction building process by refining variable types.
    • Added block hash information to transaction receipts for better data context.
    • Updated test cases to reflect changes in blockchain state and improve coverage of transaction retrieval.

Copy link
Contributor

coderabbitai bot commented Jul 18, 2024

Walkthrough

The updates across various files enhance type safety, streamline data handling, and upgrade dependencies to boost performance and maintainability. Notable changes include the replacement of deprecated methods, refinement of logging mechanisms, and the introduction of new data structures for improved encapsulation. These modifications underscore a commitment to efficient coding practices and robust functionality, ensuring the codebase remains agile and responsive to future needs.

Changes

Files Change Summary
go.mod, tests/go.mod Updated multiple dependencies, including Pebble to v1.1.1 and Cadence to v1.0.0-preview.39; included new dependency cockroachdb/fifo.
api/server.go, api/stream.go Improved logging setup and removed deprecated notifier handling in subscription management.
models/block.go, models/transaction.go Simplified handling of transaction hashes and event attributes by removing unnecessary hex decoding.
models/events.go Enhanced Transactions method to associate transaction receipts with block hashes.
services/ingestion/engine.go, services/ingestion/engine_test.go Modified event handling to use new event types from the events package; adjusted function signatures accordingly.
services/requester/requester.go Renamed and changed the type of a variable in the transaction signing process for better type safety.
tests/web3js/eth_deploy_contract_and_interact_test.js, tests/web3js/eth_non_interactive_test.js Improved formatting and assertions in test cases to reflect changes in blockchain behavior and enhance readability.

🐇 Version Song 🎶

With updates new and dependencies bright,
Our code takes flight, with versions right.
Bugs will flee and errors shrink,
As libraries new, in sync, we link.
🐰✨💻


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.

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 UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between e648106 and bd21b51.

Files ignored due to path filters (2)
  • go.sum is excluded by !**/*.sum
  • tests/go.sum is excluded by !**/*.sum
Files selected for processing (2)
  • go.mod (4 hunks)
  • tests/go.mod (7 hunks)
Additional comments not posted (26)
go.mod (22)

7-7: Approved: Update to stable version.

The update from a specific commit to a stable version v1.1.1 for github.com/cockroachdb/pebble is beneficial for stability and includes potential bug fixes and improvements.


10-10: Approved: Update to latest preview version.

The update to github.com/onflow/cadence version v1.0.0-preview.38 follows the latest preview release, which likely includes new features, improvements, and bug fixes.


11-11: Approved: Update to specific commit.

The update to github.com/onflow/flow-go to commit 9ea6faeee3e7 may include critical fixes or features not yet available in a stable release.


12-12: Approved: Update to latest preview version.

The update to github.com/onflow/flow-go-sdk version v1.0.0-preview.41 follows the latest preview release, which likely includes new features, improvements, and bug fixes.


13-13: Approved: Update to newer version.

The update to github.com/onflow/flow/protobuf/go/flow version v0.4.5 likely includes improvements and bug fixes.


14-14: Approved: Update to newer version.

The update to github.com/onflow/go-ethereum version v1.14.7 likely includes improvements and bug fixes.


21-21: Approved: Update to newer version.

The update to golang.org/x/sync version v0.7.0 likely includes improvements and bug fixes.


33-33: Approved: Update to newer version.

The update to github.com/Microsoft/go-winio version v0.6.2 likely includes improvements and bug fixes.


36-36: Approved: Update to newer version.

The update to github.com/VictoriaMetrics/fastcache version v1.12.2 likely includes improvements and bug fixes.


42-42: Approved: Update to newer version.

The update to github.com/cespare/xxhash/v2 version v2.3.0 likely includes improvements and bug fixes.


43-43: Approved: Update to newer version.

The update to github.com/cockroachdb/errors version v1.11.3 likely includes improvements and bug fixes.


46-46: Approved: Update to newer version.

The update to github.com/cockroachdb/redact version v1.1.5 likely includes improvements and bug fixes.


52-52: Approved: Update to stable version.

The update to github.com/crate-crypto/go-kzg-4844 version v1.0.0 ensures more stability and potentially includes bug fixes and improvements.


54-54: Approved: Update to newer version.

The update to github.com/deckarep/golang-set/v2 version v2.6.0 likely includes improvements and bug fixes.


61-61: Approved: Update to stable version.

The update to github.com/ethereum/c-kzg-4844 version v1.0.0 ensures more stability and potentially includes bug fixes and improvements.


70-70: Approved: Update to newer version.

The update to github.com/getsentry/sentry-go version v0.27.0 likely includes improvements and bug fixes.


73-73: Approved: Update to newer version.

The update to github.com/go-ole/go-ole version v1.3.0 likely includes improvements and bug fixes.


93-93: Approved: Update to newer version.

The update to github.com/holiman/uint256 version v1.3.0 likely includes improvements and bug fixes.


195-195: Approved: Update to newer version.

The update to golang.org/x/crypto version v0.22.0 likely includes improvements and bug fixes.


196-196: Approved: Update to newer version.

The update to golang.org/x/net version v0.24.0 likely includes improvements and bug fixes.


44-44: Verify the necessity and compatibility of the new dependency.

The addition of github.com/cockroachdb/fifo should be verified for necessity and compatibility with the existing codebase.


51-51: Verify the necessity and compatibility of the new dependency.

The addition of github.com/crate-crypto/go-ipa should be verified for necessity and compatibility with the existing codebase.

tests/go.mod (4)

7-7: Approved: Update to latest preview version.

The update to github.com/onflow/cadence version v1.0.0-preview.38 follows the latest preview release, which likely includes new features, improvements, and bug fixes.


9-9: Approved: Update to latest preview version.

The update to github.com/onflow/flow-emulator version v1.0.0-preview.35 follows the latest preview release, which likely includes new features, improvements, and bug fixes.


11-11: Approved: Update to specific commit.

The update to github.com/onflow/flow-go to commit 9ea6faeee3e7 may include critical fixes or features not yet available in a stable release.


12-12: Approved: Update to latest preview version.

The update to github.com/onflow/flow-go-sdk version v1.0.0-preview.41 follows the latest preview release, which likely includes new features, improvements, and bug fixes.

@turbolent turbolent closed this Jul 19, 2024
@turbolent turbolent reopened this Jul 19, 2024
@turbolent
Copy link
Member Author

There are several changes in flow-go and geth which need to be resolved:

  • flow-go's transaction event payload no longer includes the block hash, but it is needed for the receipt
  • flow-go's event constructors take fewer arguments
  • Logging in geth seems to have changed significantly

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

Outside diff range, codebase verification and nitpick comments (1)
models/transaction.go (1)

205-205: Clarification: BlockHash is not available.

The TODO comment clarifies that the BlockHash is not available in the event payload.

Consider using a more descriptive comment to indicate why BlockHash is not available.

- // TODO: BlockHash is not available in the event payload
+ // Note: BlockHash is not available in the event payload due to current data structure limitations.
Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between bd21b51 and d87eae9.

Files ignored due to path filters (1)
  • go.sum is excluded by !**/*.sum
Files selected for processing (5)
  • go.mod (4 hunks)
  • models/block.go (2 hunks)
  • models/transaction.go (3 hunks)
  • services/ingestion/engine_test.go (1 hunks)
  • services/requester/requester.go (5 hunks)
Files skipped from review due to trivial changes (1)
  • models/block.go
Additional comments not posted (20)
models/transaction.go (2)

195-195: Simplified assignment of Payload.

The direct assignment of Payload simplifies the function by removing unnecessary hex decoding.


200-205: Simplified assignment of transaction event attributes.

The direct assignment of Logs and ReturnedData attributes simplifies the function by removing unnecessary hex decoding.

go.mod (12)

7-7: Updated dependency: github.com/cockroachdb/pebble to v1.1.1.

The update from v0.0.0-20230928194634-aa077af62593 to v1.1.1 should improve stability and performance.


11-15: Updated dependencies: Cadence, Flow Go, Flow Go SDK, Flow protobuf, Go Ethereum.

The updates to these dependencies should enhance functionality and compatibility with the latest versions.


22-22: Updated dependency: golang.org/x/sync to v0.7.0.

The update from v0.6.0 to v0.7.0 should include bug fixes and performance improvements.


34-34: Updated dependency: github.com/Microsoft/go-winio to v0.6.2.

The update from v0.6.1 to v0.6.2 should include bug fixes and performance improvements.


37-37: Updated dependency: github.com/VictoriaMetrics/fastcache to v1.12.2.

The update from v1.12.1 to v1.12.2 should include bug fixes and performance improvements.


43-53: Updated dependencies: xxhash, cockroachdb/errors, cockroachdb/fifo, cockroachdb/redact, crate-crypto/go-kzg-4844.

The updates to these dependencies should enhance functionality and compatibility with the latest versions.


55-55: Updated dependency: github.com/deckarep/golang-set/v2 to v2.6.0.

The update from v2.1.0 to v2.6.0 should include bug fixes and performance improvements.


62-62: Updated dependency: github.com/ethereum/c-kzg-4844 to v1.0.0.

The update from v0.4.0 to v1.0.0 should enhance functionality and stability.


64-64: Updated dependency: github.com/ethereum/go-verkle to v0.1.1-0.20240306133620-7d920df305f0.

The update should include bug fixes and performance improvements.


71-74: Updated dependencies: sentry-go, go-ole.

The updates to these dependencies should enhance functionality and compatibility with the latest versions.


92-92: Updated dependency: github.com/holiman/uint256 to v1.3.0.

The update from v1.2.4 to v1.3.0 should include bug fixes and performance improvements.


194-197: Updated dependencies: golang.org/x/crypto, golang.org/x/net, golang.org/x/sys.

The updates to these dependencies should enhance functionality and compatibility with the latest versions.

services/requester/requester.go (6)

251-253: LGTM! The type update improves type safety.

The change from int to uint32 for keyIndex enhances type safety and consistency.


270-270: LGTM! The type update improves type safety.

The change from int to uint32 for keyIndex enhances type safety and consistency.


281-281: LGTM! The type update improves type safety.

The change from int to uint32 for keyIndex enhances type safety and consistency.


598-598: LGTM! The return type update improves type safety.

The change from int to uint32 for the key index return type enhances type safety and consistency.


260-262: Ensure consistent usage of keyIndex type.

Verify that all function calls to getSignerNetworkInfo and subsequent usage of keyIndex are consistent with the new uint32 type.

Verification successful

Ensure consistent usage of keyIndex type.

The keyIndex variable is consistently used as uint32 in the main code. The declaration and subsequent usages in services/requester/requester.go confirm this.

  • services/requester/requester.go: keyIndex is declared as uint32 and used consistently.
Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify the consistent usage of `keyIndex` type.

# Test: Search for the function usage. Expect: Only occurances of the new type.
rg --type go -A 5 $'getSignerNetworkInfo'

Length of output: 929


Script:

#!/bin/bash
# Description: Verify all instances of `getSignerNetworkInfo` and check the type of `keyIndex`.

# Search for all instances of `getSignerNetworkInfo` in the codebase.
rg --type go 'getSignerNetworkInfo'

# Check the type of `keyIndex` in the codebase.
rg --type go 'var keyIndex'

Length of output: 402


Script:

#!/bin/bash
# Description: Verify all instances of `keyIndex` usage in the codebase and check its type.

# Search for all instances of `keyIndex` usage in the codebase.
rg --type go 'keyIndex'

Length of output: 498


Line range hint 601-603:
Ensure consistent usage of keyIndex type.

Verify that all function calls to getSignerNetworkInfo and subsequent usage of keyIndex are consistent with the new uint32 type.

@m-Peter m-Peter self-assigned this Jul 23, 2024
@m-Peter m-Peter added this to the Flow-EVM-M2 milestone Jul 23, 2024
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 UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between d87eae9 and 09dfe64.

Files ignored due to path filters (2)
  • go.sum is excluded by !**/*.sum
  • tests/go.sum is excluded by !**/*.sum
Files selected for processing (21)
  • api/server.go (2 hunks)
  • api/stream.go (1 hunks)
  • bootstrap/create-multi-key-account.go (6 hunks)
  • go.mod (5 hunks)
  • models/events.go (1 hunks)
  • models/events_test.go (1 hunks)
  • models/receipt.go (1 hunks)
  • models/transaction.go (3 hunks)
  • models/transaction_test.go (2 hunks)
  • services/logs/filter.go (1 hunks)
  • services/logs/filter_test.go (1 hunks)
  • storage/index.go (2 hunks)
  • storage/index_testsuite.go (2 hunks)
  • storage/mocks/ReceiptIndexer.go (2 hunks)
  • storage/pebble/receipts.go (4 hunks)
  • tests/go.mod (8 hunks)
  • tests/integration_test.go (2 hunks)
  • tests/web3js/config.js (1 hunks)
  • tests/web3js/eth_deploy_contract_and_interact_test.js (8 hunks)
  • tests/web3js/eth_non_interactive_test.js (9 hunks)
  • tests/web3js/eth_revert_reason_test.js (2 hunks)
Files skipped from review due to trivial changes (3)
  • models/events_test.go
  • models/transaction_test.go
  • tests/web3js/eth_deploy_contract_and_interact_test.js
Files skipped from review as they are similar to previous changes (2)
  • models/transaction.go
  • tests/go.mod
Additional comments not posted (59)
tests/web3js/config.js (1)

9-9: Verify the appropriateness of the new startBlockHeight.

The startBlockHeight has been changed from 3n to 2n. Ensure that this new block height is appropriate for the setup and does not cause any unintended side effects in the tests or blockchain interactions.

storage/mocks/ReceiptIndexer.go (1)

22-48: Verify the correctness of the new return type handling.

The BloomsForBlockRange method now returns a slice of models.BloomsHeight and an error, instead of a tuple with an additional slice of big.Int. Ensure that the new return type is correctly handled and that the removal of the second return value does not cause any issues.

models/events.go (1)

73-92: Verify the correctness of the new block information retrieval logic.

The Transactions method now retrieves block information and associates it with transaction receipts. Ensure that the new logic correctly retrieves block information and associates it with transaction receipts without introducing any errors.

tests/web3js/eth_revert_reason_test.js (2)

46-46: Verify the correctness of the updated block number.

The expected block number in the assertion has been changed from 5n to 4n. Ensure this update aligns with the new test environment or the underlying blockchain state.


80-80: Verify the correctness of the updated block number.

The expected block number in the assertion has been changed from 6n to 5n. Ensure this update aligns with the new test environment or the underlying blockchain state.

storage/index.go (1)

87-87: Verify the correctness of the updated method signature.

The method signature for BloomsForBlockRange has been altered to return a slice of pointers to models.BloomsHeight and an error. Ensure this update aligns with the new data structure and verify its impact on the codebase.

api/stream.go (1)

Line range hint 1-100: Verify the correctness of the removal of the deprecated notifier.

The case statement handling the deprecated notifier.Closed() channel has been removed. Ensure that this removal is complete and does not affect the overall functionality of the newSubscription method.

services/logs/filter.go (4)

80-84: LGTM! The new structure simplifies data handling.

The refactoring consolidates the retrieval of bloom filters and their heights into a single structure, enhancing code clarity and maintainability.


86-90: LGTM! The iteration logic is correct.

The refactoring simplifies the iteration process by directly accessing the Blooms field from bloomsHeight.


Line range hint 94-103:
LGTM! The error handling and log processing remain intact.

The refactoring maintains the core functionality of filtering logs based on bloom criteria while simplifying the control flow.


Line range hint 175-178:
LGTM! The new type definition is correct.

The BloomsHeight structure encapsulates bloom filters and their corresponding height, enhancing the data model.

models/receipt.go (1)

175-178: LGTM! The new type definition is correct.

The BloomsHeight structure encapsulates bloom filters and their corresponding height, enhancing the data model.

tests/web3js/eth_non_interactive_test.js (9)

8-8: LGTM! The additional line enhances test clarity.

The test for retrieving the chain ID remains unchanged in logic but now includes an additional line for clarity.


32-32: LGTM! The updated transaction count reflects the current blockchain state.

The expected transaction count for a specific block has been updated from 1n to 3n, indicating a change in the blockchain state or test setup.


35-42: LGTM! The loop enhances test coverage.

The logic for retrieving transactions from a block has been altered to a loop that retrieves multiple transactions, ensuring that multiple transactions can be correctly fetched and validated.


45-45: LGTM! The updated index reflects a deeper understanding of the blockchain state.

The index for retrieving a non-existent transaction has been changed from 1 to 5.


50-55: LGTM! The simplified logic ensures robustness.

The tests for block interactions have been simplified to retrieve a block based on conf.startBlockHeight, consolidating the logic and ensuring robustness.


66-71: LGTM! The assertions validate the transaction fields correctly.

The test for block transaction retrieval includes assertions for transaction fields, ensuring they are correctly validated.


Line range hint 104-122:
LGTM! The additional assertions validate the transaction fields correctly.

The test for retrieving a transaction from a block includes additional assertions for transaction fields, ensuring they are correctly validated.


139-141: LGTM! The adjusted values reflect the current blockchain state.

The expected values for syncing status have been adjusted, reflecting changes in the expected blockchain state.


Line range hint 188-208:
LGTM! The modified results reflect the current server responses.

The expected results for batch requests have been modified, indicating a change in the server responses that the tests are designed to validate.

services/logs/filter_test.go (1)

132-148: Ensure correct data structure usage in BloomsForBlockRange.

The function now returns a slice of models.BloomsHeight, encapsulating both blooms and their heights. Ensure that the new data structure is correctly populated and returned.

-  blooms := make([]*gethTypes.Bloom, 0)
-  heights := make([]*big.Int, 0)
   bloomsHeight := make([]*models.BloomsHeight, 0)

   for _, r := range receipts {
       if r.BlockNumber.Cmp(start) >= 0 && r.BlockNumber.Cmp(end) <= 0 {
-          blooms = append(blooms, &r.Bloom)
-          heights = append(heights, r.BlockNumber)
           bloomsHeight = append(bloomsHeight, &models.BloomsHeight{
-              Blooms: blooms,
+              Blooms: []*gethTypes.Bloom{&r.Bloom},
               Height: r.BlockNumber,
           })
       }
   }

   return bloomsHeight, nil
tests/integration_test.go (2)

50-50: Ensure type consistency for keyCount.

The variable keyCount has been changed from int to uint32. Ensure that this change is consistent with its usage throughout the function.


97-100: Ensure type consistency for totalTxs and loop index.

The variable totalTxs has been changed from int to uint32, and the loop index has been updated accordingly. Ensure that this change is consistent with its usage throughout the function.

storage/pebble/receipts.go (3)

200-205: Ensure correct return type and error handling in BloomsForBlockRange.

The function's return type has been changed to a slice of models.BloomsHeight, and error handling has been streamlined. Ensure that the new data structure is correctly used and returned, and error handling is consistent.


Line range hint 211-224:
Ensure range validation in BloomsForBlockRange.

The function validates that the start and end values are within the indexed range. Ensure that this validation is correctly implemented.


Line range hint 239-274:
Ensure correct data structure usage in BloomsForBlockRange.

The function now returns a slice of models.BloomsHeight, encapsulating both blooms and their heights. Ensure that the new data structure is correctly populated and returned.

-  blooms := make([]*gethTypes.Bloom, 0)
-  heights := make([]*big.Int, 0)
   result := make([]*models.BloomsHeight, 0)

   for iterator.First(); iterator.Valid(); iterator.Next() {
       val, err := iterator.ValueAndErr()
       if err != nil {
           return nil, err
       }

       var bloomsHeight []*gethTypes.Bloom
       if err := rlp.DecodeBytes(val, &bloomsHeight); err != nil {
           return nil, fmt.Errorf("failed to decode blooms: %w", err)
       }

       h := stripPrefix(iterator.Key())
       height := new(big.Int).SetBytes(h)

-      blooms = append(blooms, bloomsHeight...)
-      heights = append(heights, height)
       result = append(result, &models.BloomsHeight{
           Blooms: bloomsHeight,
           Height: height,
       })
   }

   return result, nil
bootstrap/create-multi-key-account.go (6)

69-69: LGTM!

The change to use uint32 for the keyCount parameter enhances type safety.


78-78: LGTM!

The loop variable i is correctly updated to uint32.


158-158: LGTM!

The Index field in the flow.AccountKey struct is correctly updated to uint32.


285-285: LGTM!

The Index field in the flow.AccountKey struct is correctly updated to uint32.


51-51: Verify the function usage.

Ensure that all function calls to CreateMultiKeyAccount match the new signature.

Verification successful

Verify the type of keyCount in tests/integration_test.go.

Ensure that the keyCount parameter in tests/integration_test.go matches the new uint32 type.


Verification successful.

The function calls to CreateMultiKeyAccount match the new signature with uint32 for the keyCount parameter.

  • tests/integration_test.go: keyCount is correctly declared as uint32.
Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify all function calls to `CreateMultiKeyAccount` match the new signature.

# Test: Search for the function usage. Expect: Only occurrences of the new signature.
rg --type go -A 5 $'CreateMultiKeyAccount'

Length of output: 2342


Script:

#!/bin/bash
# Description: Verify the type of `keyCount` in `tests/integration_test.go`.

# Test: Search for the declaration of `keyCount` in `tests/integration_test.go`.
rg --type go -A 5 $'keyCount' tests/integration_test.go

Length of output: 953


219-219: Verify the function usage.

Ensure that all function calls to CreateMultiCloudKMSKeysAccount match the new signature.

Verification successful

Verify the function usage consistency in integration_test.go.

Ensure that the Index field is correctly passed as uint32 in integration_test.go.


Verify the function usage consistency in integration_test.go with more context.

Ensure that the Index field is correctly passed as uint32 by fetching additional lines around the function call in tests/integration_test.go.


Verification successful.

The function CreateMultiCloudKMSKeysAccount is used correctly in tests/integration_test.go and the change to the Index field being of type uint32 is an internal detail that does not affect the function's external usage.

  • tests/integration_test.go
Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify all function calls to `CreateMultiCloudKMSKeysAccount` match the new signature.

# Test: Search for the function usage. Expect: Only occurrences of the new signature.
rg --type go -A 5 $'CreateMultiCloudKMSKeysAccount'

Length of output: 733


Script:

#!/bin/bash
# Description: Verify if the usage of CreateMultiCloudKMSKeysAccount in integration_test.go matches the new signature.

# Test: Search for the function call and inspect the relevant lines.
rg --type go -A 5 'CreateMultiCloudKMSKeysAccount' tests/integration_test.go

Length of output: 230


Script:

#!/bin/bash
# Description: Fetch more lines around the CreateMultiCloudKMSKeysAccount function call in integration_test.go to verify the usage.

# Test: Search for the function call and fetch additional lines for full context.
rg --type go -A 10 -B 5 'CreateMultiCloudKMSKeysAccount' tests/integration_test.go

Length of output: 475

go.mod (20)

7-7: LGTM!

The update to github.com/cockroachdb/pebble v1.1.1 is approved.


11-11: LGTM!

The update to github.com/onflow/cadence v1.0.0-preview.38 is approved.


12-12: LGTM!

The update to github.com/onflow/flow-go v0.36.2-0.20240717214129-9ea6faeee3e7 is approved.


13-13: LGTM!

The update to github.com/onflow/flow-go-sdk v1.0.0-preview.41 is approved.


14-14: LGTM!

The update to github.com/onflow/flow/protobuf/go/flow v0.4.5 is approved.


15-15: LGTM!

The update to github.com/onflow/go-ethereum v1.14.7 is approved.


22-22: LGTM!

The update to golang.org/x/sync v0.7.0 is approved.


34-34: LGTM!

The update to github.com/Microsoft/go-winio v0.6.2 is approved.


37-37: LGTM!

The update to github.com/VictoriaMetrics/fastcache v1.12.2 is approved.


43-43: LGTM!

The update to github.com/cespare/xxhash/v2 v2.3.0 is approved.


7-7: Verify compatibility with the project.

Ensure that the update to github.com/cockroachdb/pebble v1.1.1 is compatible with the project.


11-11: Verify compatibility with the project.

Ensure that the update to github.com/onflow/cadence v1.0.0-preview.38 is compatible with the project.


34-34: Verify compatibility with the project.

Ensure that the update to github.com/Microsoft/go-winio v0.6.2 is compatible with the project.

Verification successful

The update to github.com/Microsoft/go-winio v0.6.2 is compatible with the project.

The dependency is indirect and does not have direct references in the project's Go files. The update from v0.6.1 to v0.6.2 should not introduce breaking changes.

Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify compatibility of `github.com/Microsoft/go-winio v0.6.2` with the project.

# Test: Search for the dependency usage. Expect: No breaking changes.
rg --type go -A 5 $'go-winio'

Length of output: 28


Script:

#!/bin/bash
# Description: Verify compatibility of `github.com/Microsoft/go-winio v0.6.2` with the project.

# Test: Search for the dependency usage with a broader pattern. Expect: No breaking changes.
rg --type go -A 5 'winio'

Length of output: 25


Script:

#!/bin/bash
# Description: Verify compatibility of `github.com/Microsoft/go-winio v0.6.2` with the project by checking `go.mod` and `go.sum`.

# Check `go.mod` for references to `go-winio`.
rg 'go-winio' go.mod

# Check `go.sum` for references to `go-winio`.
rg 'go-winio' go.sum

Length of output: 360


37-37: Verify compatibility with the project.

Ensure that the update to github.com/VictoriaMetrics/fastcache v1.12.2 is compatible with the project.


13-13: Verify compatibility with the project.

Ensure that the update to github.com/onflow/flow-go-sdk v1.0.0-preview.41 is compatible with the project.

Verification successful

Verify compatibility with the project.

The update to github.com/onflow/flow-go-sdk v1.0.0-preview.41 is compatible with the project. The AccountKey structure usage in the project aligns with the changes in the new version.

  • bootstrap/create-multi-key-account.go
Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify compatibility of `github.com/onflow/flow-go-sdk v1.0.0-preview.41` with the project.

# Test: Search for the dependency usage. Expect: No breaking changes.
rg --type go -A 5 $'flow-go-sdk'

Length of output: 12260


Script:

#!/bin/bash
# Description: Check the changelog or release notes of `github.com/onflow/flow-go-sdk` for breaking changes between `v1.0.0-preview.38` and `v1.0.0-preview.41`.

# Fetch the changelog or release notes from the GitHub repository.
gh api repos/onflow/flow-go-sdk/releases --jq '.[] | select(.tag_name == "v1.0.0-preview.41" or .tag_name == "v1.0.0-preview.38") | {tag_name, body}'

Length of output: 989


Script:

#!/bin/bash
# Description: Search for the usage of flow account key id in the project to determine if the change to uint32 impacts the project.

# Search for the usage of flow account key id.
rg --type go 'flow\.AccountKey\.ID'

Length of output: 37


Script:

#!/bin/bash
# Description: Search for any usage of AccountKey in the project to determine if the change to uint32 impacts the project.

# Search for the usage of AccountKey.
rg --type go 'AccountKey'

Length of output: 558


Script:

#!/bin/bash
# Description: Extract relevant lines from `bootstrap/create-multi-key-account.go` to review the usage of `AccountKey`.

# Extract lines around the usage of `AccountKey`.
rg --type go -A 5 -B 5 'AccountKey' bootstrap/create-multi-key-account.go

Length of output: 1564


22-22: Verify compatibility with the project.

Ensure that the update to golang.org/x/sync v0.7.0 is compatible with the project.

Verification successful

Verify compatibility with the project.

The update to golang.org/x/sync v0.7.0 is compatible with the project. There are no breaking changes in the errgroup package that affect its usage in the codebase.

  • The only commit between v0.6.0 and v0.7.0 is related to the semaphore package and does not impact errgroup.
Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify compatibility of `golang.org/x/sync v0.7.0` with the project.

# Test: Search for the dependency usage. Expect: No breaking changes.
rg --type go -A 5 $'x/sync'

Length of output: 439


Script:

#!/bin/bash
# Extract the relevant code from services/requester/requester.go where errgroup is used
rg --type go -A 20 'errgroup' services/requester/requester.go

Length of output: 1034


Script:

#!/bin/bash
# Fetch and compare the changelog or release notes for golang.org/x/sync between versions v0.6.0 and v0.7.0

# Fetch the changelog
curl -s https://pkg.go.dev/golang.org/x/[email protected] | grep -A 10 'v0.7.0'
curl -s https://pkg.go.dev/golang.org/x/[email protected] | grep -A 10 'v0.6.0'

Length of output: 9907


Script:

#!/bin/bash
# Search for changelog or release notes in the golang.org/x/sync repository

# Clone the repository
git clone https://go.googlesource.com/sync

# Check for changelog or release notes
cd sync
git log v0.6.0..v0.7.0 --oneline

Length of output: 232


14-14: Verify compatibility with the project.

Ensure that the update to github.com/onflow/flow/protobuf/go/flow v0.4.5 is compatible with the project.


43-43: Verify compatibility with the project.

Ensure that the update to github.com/cespare/xxhash/v2 v2.3.0 is compatible with the project.


15-15: Verify compatibility with the project.

Ensure that the update to github.com/onflow/go-ethereum v1.14.7 is compatible with the project.


12-12: Verify compatibility with the project.

Ensure that the update to github.com/onflow/flow-go v0.36.2-0.20240717214129-9ea6faeee3e7 is compatible with the project.

api/server.go (1)

64-72: Verify the logging configuration.

Ensure that the new logging configuration using gethLog.SetDefault with a terminal handler targeting error-level logs is correctly set up.

#!/bin/bash
# Description: Verify

<details>
<summary>Verification successful</summary>



---

<!-- [monologue]
[task review_file_3/3 function_1/1] Verify the logging configuration in the `NewHTTPServer` function.
[observations] The `NewHTTPServer` function in `api/server.go` includes the logging configuration using `gethLog.SetDefault` with a terminal handler targeting error-level logs. The function then returns an instance of `httpServer` with the provided logger and configuration.
[analysis] The logging setup is correctly implemented within the `NewHTTPServer` function, and there are no conflicting logging configurations present.
[actions] Conclude the verification process by confirming the correctness of the logging configuration.
-->

**Verified the logging configuration.**

The `NewHTTPServer` function correctly sets up the logging configuration using `gethLog.SetDefault` with a terminal handler targeting error-level logs.

- `api/server.go`:
  - `NewHTTPServer` function: Lines 64-72



</details>


<details>
<summary>Scripts executed</summary>

The following scripts were executed for the analysis:



---

Script:

```shell
#!/bin/bash
# Locate and review the NewHTTPServer function in api/server.go to verify the logging configuration
ast-grep --lang go --pattern $'func NewHTTPServer($_, $_, $_) $_ {
  $$$
}' --json

Length of output: 86


Script:

#!/bin/bash
# Search for the NewHTTPServer function definition across the entire codebase
rg 'func NewHTTPServer' -A 10

Length of output: 405


Script:

#!/bin/bash
# Extract the entire NewHTTPServer function from api/server.go to verify the logging configuration
ast-grep --lang go --pattern $'func NewHTTPServer($_, $_) $_ {
  $$$
}' api/server.go

Length of output: 695

storage/index_testsuite.go (5)

261-261: Verify the consistency of the length check.

The length of bloomsHeights is being checked against testBlooms. Ensure that this length check is valid and consistent with the expected output.


259-259: Verify the correct usage of the new return type.

The variable bloomsHeights is introduced to handle the return value from s.ReceiptIndexer.BloomsForBlockRange. Ensure that this change aligns with the new return type of the method.

Verification successful

Verified the correct usage of the new return type.

The method BloomsForBlockRange returns ([]*models.BloomsHeight, error), and the variable bloomsHeights correctly handles this return type.

  • storage/pebble/receipts.go
  • storage/mocks/ReceiptIndexer.go
Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify the return type of the method `BloomsForBlockRange`.

# Test: Search for the method definition. Expect: The method returns a single structure or tuple.
rg --type go -A 5 'func (r *ReceiptIndexer) BloomsForBlockRange'

Length of output: 66


Script:

#!/bin/bash
# Description: Verify the return type of the method `BloomsForBlockRange`.

# Test: Search for the method definition with a more inclusive pattern.
rg --type go 'func BloomsForBlockRange' -A 10

Length of output: 47


Script:

#!/bin/bash
# Description: Verify the return type of the method `BloomsForBlockRange`.

# Test: Search for all method definitions in the codebase to locate `BloomsForBlockRange`.
rg --type go 'func ' -A 10 | grep -A 10 'BloomsForBlockRange'

Length of output: 2884


288-288: Verify the correct reuse of the variable.

The variable bloomsHeights is reused to handle the return value from s.ReceiptIndexer.BloomsForBlockRange for another block range. Ensure that this change aligns with the new return type of the method.

Verification successful

The variable reuse is correct.

The method BloomsForBlockRange returns ([]*models.BloomsHeight, error), which aligns with the reuse of the variable bloomsHeights in the code snippet.

  • storage/pebble/receipts.go: BloomsForBlockRange
  • storage/mocks/ReceiptIndexer.go: BloomsForBlockRange
Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify the correct reuse of the variable.

# Test: Search for the method definition. Expect: The method returns a single structure or tuple.
rg --type go -A 5 'func (r *ReceiptIndexer) BloomsForBlockRange'

Length of output: 66


Script:

#!/bin/bash
# Description: Verify the correct reuse of the variable.

# Test: Search for the method definition. Expect: The method returns a single structure or tuple.
rg --type go -A 10 'func .*BloomsForBlockRange'

Length of output: 2129


266-266: Verify the correct reuse of the variable.

The variable bloomsHeights is reused to handle the return value from s.ReceiptIndexer.BloomsForBlockRange for a different block range. Ensure that this change aligns with the new return type of the method.

Verification successful

The reuse of the variable bloomsHeights is correct.

The method BloomsForBlockRange returns a slice of *models.BloomsHeight and an error, which aligns with the expected usage where bloomsHeights is assigned the first return value.

  • storage/index.go: BloomsForBlockRange(start, end *big.Int) ([]*models.BloomsHeight, error)
  • storage/mocks/ReceiptIndexer.go:func (_m *ReceiptIndexer) BloomsForBlockRange(start *big.Int, end *big.Int) ([]*models.BloomsHeight, error)
  • storage/pebble/receipts.go:func (r *Receipts) BloomsForBlockRange(start, end *big.Int) ([]*models.BloomsHeight, error)
Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify the correct reuse of the variable.

# Test: Search for the method definition. Expect: The method returns a single structure or tuple.
rg --type go -A 5 'func (r *ReceiptIndexer) BloomsForBlockRange'

Length of output: 66


Script:

#!/bin/bash
# Description: Verify the correct reuse of the variable.

# Test: Search for the method definition using ast-grep. Expect: The method returns a single structure or tuple.
ast-grep --lang go --pattern 'func (r *ReceiptIndexer) BloomsForBlockRange($_, $_) ($_,$$$)'

Length of output: 94


Script:

#!/bin/bash
# Description: Verify the correct reuse of the variable.

# Test: Search for the method definition using rg. Expect: The method definition should be found in the Go codebase.
rg --type go 'BloomsForBlockRange'

Length of output: 1500


299-299: Verify the correct usage of the variable.

The variable bloomsHeights is used to handle the return value from s.ReceiptIndexer.BloomsForBlockRange for an invalid block range. Ensure that this change aligns with the new return type of the method.

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 UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 09dfe64 and c79f9b4.

Files selected for processing (1)
  • tests/web3js/eth_non_interactive_test.js (10 hunks)
Files skipped from review as they are similar to previous changes (1)
  • tests/web3js/eth_non_interactive_test.js

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 UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between c79f9b4 and 977fb43.

Files ignored due to path filters (2)
  • go.sum is excluded by !**/*.sum
  • tests/go.sum is excluded by !**/*.sum
Files selected for processing (2)
  • go.mod (4 hunks)
  • tests/go.mod (8 hunks)
Files skipped from review as they are similar to previous changes (2)
  • go.mod
  • tests/go.mod

@turbolent turbolent changed the title Update to Cadence v1.0.0-preview.38 Update to Cadence v1.0.0-preview.39 Jul 25, 2024
@turbolent
Copy link
Member Author

@m-Peter @sideninja The fixes in the dependencies are merged now:

Releases have been tagged in the dependencies, and I updated everything again, which resulted in #382, which I merged into this PR.

It looks like the EVM implementation changed once again and block transaction hashes have been replaced by a transaction hash root. However, I don't know anything about these. From what I can tell this should be the last issue that has to be addressed. Let me know how I can assist!

cc @ramtinms

TxHash: txEvent.Hash,
ContractAddress: common.HexToAddress(txEvent.ContractAddress),
GasUsed: txEvent.GasConsumed,
CumulativeGasUsed: txEvent.GasConsumed, // todo use cumulative after added to the tx result
Copy link
Member Author

Choose a reason for hiding this comment

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

This might be a bad merge (re-)introducing it, not sure

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 UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 977fb43 and 9a4acf9.

Files ignored due to path filters (2)
  • go.sum is excluded by !**/*.sum
  • tests/go.sum is excluded by !**/*.sum
Files selected for processing (17)
  • api/server.go (2 hunks)
  • api/stream.go (1 hunks)
  • go.mod (5 hunks)
  • models/block.go (2 hunks)
  • models/block_test.go (1 hunks)
  • models/events.go (4 hunks)
  • models/events_test.go (2 hunks)
  • models/transaction.go (4 hunks)
  • models/transaction_test.go (3 hunks)
  • services/ingestion/engine.go (1 hunks)
  • services/ingestion/engine_test.go (3 hunks)
  • services/ingestion/subscriber.go (2 hunks)
  • services/requester/requester.go (5 hunks)
  • storage/mocks/mocks.go (1 hunks)
  • tests/go.mod (8 hunks)
  • tests/web3js/eth_deploy_contract_and_interact_test.js (8 hunks)
  • tests/web3js/eth_non_interactive_test.js (11 hunks)
Files skipped from review due to trivial changes (4)
  • api/stream.go
  • models/transaction_test.go
  • storage/mocks/mocks.go
  • tests/web3js/eth_deploy_contract_and_interact_test.js
Files skipped from review as they are similar to previous changes (8)
  • api/server.go
  • models/block.go
  • models/events.go
  • models/events_test.go
  • models/transaction.go
  • services/ingestion/engine_test.go
  • services/requester/requester.go
  • tests/web3js/eth_non_interactive_test.js
Additional comments not posted (20)
models/block_test.go (2)

7-9: LGTM! Import statements updated correctly.

The import statements have been updated to use the events package from flow-go/fvm/evm, aligning with the updated event handling logic in the Flow framework.


17-25: LGTM! Function updated correctly.

The function has been updated to use events.NewBlockEvent and block.TransactionHashRoot, aligning with the updated event handling logic in the Flow framework.

services/ingestion/subscriber.go (2)

9-9: LGTM! Import statements updated correctly.

The import statements have been updated to use the events package from flow-go/fvm/evm, aligning with the updated event handling logic in the Flow framework.


237-243: LGTM! Function updated correctly.

The function has been updated to use events.EventTypeBlockExecuted and events.EventTypeTransactionExecuted, aligning with the updated event handling logic in the Flow framework.

services/ingestion/engine.go (1)

210-217: LGTM! Logging updated correctly.

The function has been updated to log block.TransactionHashRoot instead of individual transaction hashes, simplifying the logging process and aligning with the updated event handling logic in the Flow framework.

go.mod (11)

7-7: Approve the update to github.com/cockroachdb/pebble.

The update moves the dependency from a pre-release version to a stable release, which is generally beneficial. Ensure that the new version does not introduce breaking changes.

Verification successful

Approve the update to github.com/cockroachdb/pebble.

The update moves the dependency from a pre-release version to a stable release, which is generally beneficial. Ensure that the new version does not introduce breaking changes by reviewing the official release notes or changelog for pebble v1.1.1.

Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify compatibility of the updated `github.com/cockroachdb/pebble` dependency.

# Test: Check for breaking changes in the new version.
rg --type go -A 5 'pebble'

Length of output: 34658


11-11: Approve the update to github.com/onflow/cadence.

The update is a minor version change within the preview releases. Ensure that the new version does not introduce breaking changes.


37-37: Approve the update to github.com/VictoriaMetrics/fastcache.

The update is a minor version change. Ensure that the new version does not introduce breaking changes.


43-43: Approve the update to github.com/cespare/xxhash/v2.

The update is a minor version change. Ensure that the new version does not introduce breaking changes.

Verification successful

The dependency github.com/cespare/xxhash/v2 is not directly imported or used in the codebase.

Since it is an indirect dependency, it is likely used by another package. The update to v2.3.0 should be safe, but it is recommended to verify the compatibility of the dependent package.

Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify compatibility of the updated `github.com/cespare/xxhash/v2` dependency.

# Test: Check for breaking changes in the new version.
rg --type go -A 5 'xxhash/v2'

Length of output: 29


Script:

#!/bin/bash
# Description: Search for import statements of the updated `github.com/cespare/xxhash/v2` dependency.

# Find all Go files that import `xxhash/v2`.
rg --type go 'import "github.com/cespare/xxhash/v2"' -l

Length of output: 57


Script:

#!/bin/bash
# Description: Search for usage of the `xxhash` package from `github.com/cespare/xxhash/v2` in the codebase.

# Find all instances where `xxhash` is used in the codebase.
rg --type go 'xxhash\.' -A 5

Length of output: 30


13-13: Approve the update to github.com/onflow/flow-go-sdk.

The update is a minor version change within the preview releases. Ensure that the new version does not introduce breaking changes.

Verification successful

Approve the update to github.com/onflow/flow-go-sdk.

The release notes for the updated version do not indicate any breaking changes. Please verify the functionality by running the relevant tests to ensure compatibility.

Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify compatibility of the updated `github.com/onflow/flow-go-sdk` dependency.

# Test: Check for breaking changes in the new version.
rg --type go -A 5 'flow-go-sdk'

Length of output: 12226


Script:

#!/bin/bash
# Description: Fetch the changelog or release notes for `github.com/onflow/flow-go-sdk` to verify changes between v1.0.0-preview.38 and v1.0.0-preview.42.

# Fetch the changelog or release notes from the repository.
curl -s https://api.github.com/repos/onflow/flow-go-sdk/releases | jq -r '.[] | select(.tag_name == "v1.0.0-preview.42" or .tag_name == "v1.0.0-preview.38") | .body'

Length of output: 865


34-34: Approve the update to github.com/Microsoft/go-winio.

The update is a minor version change. Ensure that the new version does not introduce breaking changes.

Verification successful

Approve the update to github.com/Microsoft/go-winio.

The update is a minor version change from v0.6.1 to v0.6.2. There are no direct usages of go-winio found in the codebase, and it is listed as an indirect dependency. Ensure that the indirect dependencies that rely on go-winio are compatible with the new version.

  • go.mod:
    • github.com/Microsoft/go-winio v0.6.2 // indirect
  • go.sum:
    • github.com/Microsoft/go-winio v0.6.2
Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify compatibility of the updated `github.com/Microsoft/go-winio` dependency.

# Test: Check for breaking changes in the new version.
rg --type go -A 5 'go-winio'

Length of output: 28


Script:

#!/bin/bash
# Description: Verify compatibility of the updated `github.com/Microsoft/go-winio` dependency.

# Search for usage of `go-winio` in the codebase.
rg 'go-winio'

# Check the `go.mod` file for the version of `go-winio`.
rg 'github.com/Microsoft/go-winio' go.mod

# Check the `go.sum` file for the version of `go-winio`.
rg 'github.com/Microsoft/go-winio' go.sum

Length of output: 1134


22-22: Approve the update to golang.org/x/sync.

The update is a minor version change. Ensure that the new version does not introduce breaking changes.


44-44: Approve the update to github.com/cockroachdb/errors.

The update includes a minor version change. Ensure that the new version does not introduce breaking changes.


14-14: Approve the update to github.com/onflow/flow/protobuf/go/flow.

The update is a minor version change. Ensure that the new version does not introduce breaking changes.

Verification successful

Approve the update to github.com/onflow/flow/protobuf/go/flow to version v0.4.5.

The newly added methods GetAccountBalance* and GetAccountKeys* are not used in the project's codebase. However, ensure that other changes in the update do not affect the existing functionality by performing a manual verification.

Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify compatibility of the updated `github.com/onflow/flow/protobuf/go/flow` dependency.

# Test: Check for breaking changes in the new version.
rg --type go -A 5 'protobuf/go/flow'

Length of output: 1024


Script:

#!/bin/bash
# Description: Fetch the changelog or release notes for `github.com/onflow/flow` to identify any breaking changes or new features in version `v0.4.5`.

# Fetch the changelog or release notes from the GitHub repository.
curl -s https://api.github.com/repos/onflow/flow/releases | jq -r '.[] | select(.tag_name=="v0.4.5") | .body'

Length of output: 1930


Script:

#!/bin/bash
# Description: Verify the usage of newly added methods `GetAccountBalance*` and `GetAccountKeys*` in the project's codebase.

# Search for the usage of `GetAccountBalance*` and `GetAccountKeys*` in the project's Go files.
rg --type go 'GetAccountBalance'
rg --type go 'GetAccountKeys'

Length of output: 62


12-12: Approve the update to github.com/onflow/flow-go.

The update includes a minor version change and a specific commit reference. Ensure that the new version does not introduce breaking changes.


15-15: Approve the update to github.com/onflow/go-ethereum.

The update includes a major version change. Ensure that the new version does not introduce breaking changes.

tests/go.mod (4)

11-11: Approve the update to github.com/onflow/flow-go.

The update includes a minor version change and a specific commit reference. Ensure that the new version does not introduce breaking changes.


12-12: Approve the update to github.com/onflow/flow-go-sdk.

The update is a minor version change within the preview releases. Ensure that the new version does not introduce breaking changes.


7-7: Approve the update to github.com/onflow/cadence.

The update is a minor version change within the preview releases. Ensure that the new version does not introduce breaking changes.


9-9: Approve the update to github.com/onflow/flow-emulator.

The update is a minor version change within the preview releases. Ensure that the new version does not introduce breaking changes.

@m-Peter
Copy link
Collaborator

m-Peter commented Jul 25, 2024

@turbolent We have incrementally fixed all the breaking changes, via:

So now we have github.com/onflow/cadence v1.0.0-preview.39 in #381, which a ✔️ CI 🙏

@sideninja
Copy link
Contributor

Closing this one in favour of #381
There are a lot of breaking changes that needs addressing.

@sideninja sideninja closed this Jul 25, 2024
@turbolent
Copy link
Member Author

Awesome, great work @m-Peter and @sideninja! 👏

@m-Peter m-Peter deleted the auto-update-onflow-cadence-v1.0.0-preview.38 branch August 22, 2024 08:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: ✅ Done
Development

Successfully merging this pull request may close these issues.

3 participants