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

Start using chainlink-framework/chains instead of chainlink/common. #15972

Draft
wants to merge 12 commits into
base: develop
Choose a base branch
from

Conversation

pavel-raykov
Copy link
Collaborator

@pavel-raykov pavel-raykov commented Jan 17, 2025

This PR starts using newly created module chainlink-framework/chains instead of chainlink/common. It essentially does the following steps:

  • removes non-mock .go files from chainlink/common.
  • points the rest of the code to import chainlink-framework/chains by running the following substitutions in the relevant files
cat /tmp/grep_files.txt | while read line 
do
   sed -i '' -e 's="github.com/smartcontractkit/chainlink/v2/common/fees"="github.com/smartcontractkit/chainlink-framework/chains/fees"=' $line
   sed -i '' -e 's="github.com/smartcontractkit/chainlink/v2/common/txmgr"="github.com/smartcontractkit/chainlink-framework/chains/txmgr"=' $line
   sed -i '' -e 's="github.com/smartcontractkit/chainlink/v2/common/txmgr/types"="github.com/smartcontractkit/chainlink-framework/chains/txmgr/types"=' $line
   sed -i '' -e 's="github.com/smartcontractkit/chainlink/v2/common/types"="github.com/smartcontractkit/chainlink-framework/chains"=' $line
   sed -i '' -e 's="github.com/smartcontractkit/chainlink/v2/common/headtracker"="github.com/smartcontractkit/chainlink-framework/chains/headtracker"=' $line
   sed -i '' -e 's="github.com/smartcontractkit/chainlink/v2/common/headtracker/types"="github.com/smartcontractkit/chainlink-framework/chains/headtracker/types"=' $line
done
  • updates .mockery.yaml file to generate mocks based on the chainlink-framework/chains.

@pavel-raykov pavel-raykov requested a review from jmank88 January 17, 2025 17:25
@pavel-raykov pavel-raykov changed the title Move chainlink/common to chainlink-framework/chains. Start using chainlink-framework/chains instead of chainlink/common. Jan 17, 2025
Copy link
Contributor

github-actions bot commented Jan 17, 2025

AER Report: CI Core ran successfully ✅

aer_workflow , commit

AER Report: Operator UI CI ran successfully ✅

aer_workflow , commit

go.mod Outdated
Comment on lines 412 to 413

github.com/smartcontractkit/chainlink-framework/chains => /Users/pavelraykov/Pavel_dev/chainlink-framework/chains
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
github.com/smartcontractkit/chainlink-framework/chains => /Users/pavelraykov/Pavel_dev/chainlink-framework/chains

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Sure, go.mod will have to be changed anyway with the newly committed version.

Copy link
Contributor

Choose a reason for hiding this comment

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

You can update to the PR branch commit to get CI working before merge.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Done. Now CI Core / Clean Go Tidy & Generate passes!

Copy link
Contributor

Flakeguard Summary

Ran new or updated tests between develop and 3c2bacb (test-common-removed).

View Flaky Detector Details | Compare Changes

Found Flaky Tests ❌

Name Pass Ratio Panicked? Timed Out? Race? Runs Successes Failures Skips Package Package Panicked? Avg Duration Code Owners
TestETHKeysController_ChainSuccess_UpdateNonce 66.67% false false false 3 2 1 0 github.com/smartcontractkit/chainlink/v2/core/web false 1.373333333s Unknown
TestTransfersController_CreateSuccess_From 66.67% false false false 3 2 1 0 github.com/smartcontractkit/chainlink/v2/core/web false 1.366666666s Unknown

Artifacts

For detailed logs of the failed tests, please refer to the artifact failed-test-results-with-logs.json.

@cl-sonarqube-production
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants