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

[WIP] Mock Capability #16259

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

[WIP] Mock Capability #16259

wants to merge 2 commits into from

Conversation

george-dorin
Copy link
Contributor

No description provided.

Copy link
Contributor

github-actions bot commented Feb 6, 2025

AER Report: CI Core

aer_workflow , commit , Clean Go Tidy & Generate , Detect Changes , Scheduled Run Frequency , Core Tests (go_core_tests) , Core Tests (go_core_tests_integration) , Core Tests (go_core_ccip_deployment_tests) , Core Tests (go_core_fuzz) , Core Tests (go_core_race_tests) , GolangCI Lint (integration-tests) , test-scripts , lint , SonarQube Scan

1. GolangCI Lint job failed: lint

Source of Error:
Check Golangci-lint Matrix Results	2025-02-06T15:50:20.5859576Z ##[error]Process completed with exit code 1.

Why: The GolangCI Lint job encountered issues in the code that did not meet the linting standards, causing the job to fail.

Suggested fix: Review the linting errors reported by GolangCI Lint and correct the code to adhere to the linting rules.

2. Comment formatting issues: Golang Lint (integration-tests)

Source of Error:
Golang Lint (integration-tests)	2025-02-06T15:50:09.0973417Z ##[error]integration-tests/smoke/capabilities/proxy_test.go:95:64: commentFormatting: put a space between `//` and comment text (gocritic)
Golang Lint (integration-tests)	2025-02-06T15:50:09.0975357Z 	createNodeJobsWithJd(t, ctfEnv, don, bc, keystoneContractSet) //TODO @george-dorin: Split this so we don't create the cron cap job
Golang Lint (integration-tests)	2025-02-06T15:50:09.0976880Z 	 ^
Golang Lint (integration-tests)	2025-02-06T15:50:09.0978958Z ##[error]integration-tests/smoke/capabilities/proxy_test.go:104:2: commentFormatting: put a space between `//` and comment text (gocritic)
Golang Lint (integration-tests)	2025-02-06T15:50:09.0979910Z 	//Start proxy cap job
Golang Lint (integration-tests)	2025-02-06T15:50:09.0980281Z 	^
Golang Lint (integration-tests)	2025-02-06T15:50:09.0981566Z ##[error]integration-tests/smoke/capabilities/proxy_test.go:119:2: commentFormatting: put a space between `//` and comment text (gocritic)
Golang Lint (integration-tests)	2025-02-06T15:50:09.0982543Z 	//TODO @george-dorin: FixME!
Golang Lint (integration-tests)	2025-02-06T15:50:09.0982923Z 	^

Why: The comments in the code do not have a space between // and the comment text, which violates the linting rules.

Suggested fix: Add a space between // and the comment text in the specified lines.

3. Copylocks issue: Golang Lint (integration-tests)

Source of Error:
Golang Lint (integration-tests)	2025-02-06T15:50:09.0986114Z ##[error]integration-tests/smoke/capabilities/proxy_test.go:251:97: copylocks: call of fmt.Sprintf copies lock value: github.com/smartcontractkit/chainlink/integration-tests/smoke/capabilities.SendTriggerRequest contains google.golang.org/protobuf/internal/impl.MessageState contains sync.Mutex (govet)
Golang Lint (integration-tests)	2025-02-06T15:50:09.0988284Z 		framework.L.Info().Msg(fmt.Sprintf("Sending trigger response to %s: %v+", c.pID2CapID[id][i], data))
Golang Lint (integration-tests)	2025-02-06T15:50:09.0990410Z 		 ^

Why: The fmt.Sprintf function is copying a lock value, which can lead to potential issues with concurrency.

Suggested fix: Avoid copying lock values by restructuring the code to not pass lock-containing structures to fmt.Sprintf.

4. Ineffectual assignment to err: Golang Lint (integration-tests)

Source of Error:
Golang Lint (integration-tests)	2025-02-06T15:50:09.0991594Z ##[error]integration-tests/smoke/capabilities/proxy_test.go:139:18: ineffectual assignment to err (ineffassign)
Golang Lint (integration-tests)	2025-02-06T15:50:09.0992456Z 	wrappedPayload, err := values.WrapMap(payload)
Golang Lint (integration-tests)	2025-02-06T15:50:09.0992978Z 	 ^
Golang Lint (integration-tests)	2025-02-06T15:50:09.0993971Z ##[error]integration-tests/smoke/capabilities/proxy_test.go:183:20: ineffectual assignment to err (ineffassign)
Golang Lint (integration-tests)	2025-02-06T15:50:09.0994870Z 			wrappedPayload, err = values.WrapMap(payload)
Golang Lint (integration-tests)	2025-02-06T15:50:09.0995568Z 			 ^

Why: The variable err is assigned a value but never used, which is considered an ineffectual assignment.

Suggested fix: Use the err variable after assignment or remove the assignment if it is not needed.

5. Go module changes detected: Clean Go Tidy & Generate

Source of Error:
Ensure clean after tidy	2025-02-06T15:56:30.1608594Z ##[error]Process completed with exit code 1.

Why: The go.mod file was modified after running go mod tidy, indicating that the repository is not clean.

Suggested fix: Commit the changes to go.mod or ensure that go mod tidy does not modify the file by resolving any discrepancies in dependencies.

AER Report: Operator UI CI ran successfully ✅

aer_workflow , commit

@cl-sonarqube-production
Copy link

Quality Gate passed Quality Gate passed

Issues
0 New issues
0 Fixed issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarQube

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

Successfully merging this pull request may close these issues.

1 participant